Do not ICE on unicode next point

Use `shrink_to_hi` instead of `next_point`
Fix #68000.
This commit is contained in:
Esteban Küber 2020-01-09 22:10:18 -08:00
parent 72b2bd55ed
commit fcd850fc5d
3 changed files with 24 additions and 1 deletions

View file

@ -0,0 +1,6 @@
pub struct Foo {
pub bar: Vec<i32>ö
//~^ ERROR expected `,`, or `}`, found `ö`
} //~ ERROR expected `:`, found `}`
fn main() {}

View file

@ -0,0 +1,17 @@
error: expected `,`, or `}`, found `ö`
--> $DIR/issue-68000-unicode-ident-after-missing-comma.rs:2:22
|
LL | pub bar: Vec<i32>ö
| ^ help: try adding a comma: `,`
error: expected `:`, found `}`
--> $DIR/issue-68000-unicode-ident-after-missing-comma.rs:4:1
|
LL | pub bar: Vec<i32>ö
| - expected `:`
LL |
LL | }
| ^ unexpected token
error: aborting due to 2 previous errors