diff options
author | pcpthm <[email protected]> | 2019-03-21 19:33:05 +0000 |
---|---|---|
committer | pcpthm <[email protected]> | 2019-03-21 23:09:11 +0000 |
commit | edbc18516d211c8dbf07539358c7d8aeca24bb30 (patch) | |
tree | 8248cbc937b1cf332fae009a41472e4f2eccf841 /crates/ra_syntax/src | |
parent | 7669113e7c9088a2b656c720cca5c2e46e3cb896 (diff) |
Fix reparsing bug on "{}{}"
Diffstat (limited to 'crates/ra_syntax/src')
-rw-r--r-- | crates/ra_syntax/src/parsing/reparsing.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_syntax/src/parsing/reparsing.rs b/crates/ra_syntax/src/parsing/reparsing.rs index 3b5471bf8..d54669a95 100644 --- a/crates/ra_syntax/src/parsing/reparsing.rs +++ b/crates/ra_syntax/src/parsing/reparsing.rs | |||
@@ -111,7 +111,7 @@ fn is_balanced(tokens: &[Token]) -> bool { | |||
111 | return false; | 111 | return false; |
112 | } | 112 | } |
113 | let mut balance = 0usize; | 113 | let mut balance = 0usize; |
114 | for t in tokens.iter() { | 114 | for t in &tokens[1..tokens.len() - 1] { |
115 | match t.kind { | 115 | match t.kind { |
116 | L_CURLY => balance += 1, | 116 | L_CURLY => balance += 1, |
117 | R_CURLY => { | 117 | R_CURLY => { |