]> git.lizzy.rs Git - rust.git/commit
Recover from parse errors in struct literal fields
authorEsteban Küber <esteban@kuber.com.ar>
Sun, 20 Jan 2019 08:37:06 +0000 (00:37 -0800)
committerEsteban Küber <esteban@kuber.com.ar>
Sun, 20 Jan 2019 08:37:06 +0000 (00:37 -0800)
commitb1f169fe7a19cf10f70ee2aa2513276185c70e9b
treedd0b3328c61a882bc0b0ff4436e6eb997a97ccda
parent0c0c585281740aba4c91cbfd385f5e1fbe313d11
Recover from parse errors in struct literal fields

Attempt to recover from parse errors while parsing a struct's literal fields
by skipping tokens until a comma or the closing brace is found. This allows
errors in other fields to be reported.
src/libsyntax/parse/parser.rs
src/test/ui/issues/issue-52496.rs [new file with mode: 0644]
src/test/ui/issues/issue-52496.stderr [new file with mode: 0644]
src/test/ui/parser/removed-syntax-with-1.stderr
src/test/ui/parser/removed-syntax-with-2.stderr
src/test/ui/parser/struct-field-numeric-shorthand.rs
src/test/ui/parser/struct-field-numeric-shorthand.stderr