Skip to content

Commit

Permalink
Fix parser bug on tupplestruct pattern
Browse files Browse the repository at this point in the history
gcc/rust/ChangeLog:

	* parse/rust-parse-impl.h: Add missing token consumption

Signed-off-by: Jakub Dupak <[email protected]>
  • Loading branch information
jdupak authored and P-E-P committed Oct 5, 2023
1 parent c7728c8 commit 10fd060
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions gcc/rust/parse/rust-parse-impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -11452,6 +11452,8 @@ Parser<ManagedTokenSource>::parse_struct_pattern_field_partial (
std::string index_str = t->get_str ();
int index = atoi (index_str.c_str ());

lexer.skip_token ();

if (!skip_token (COLON))
{
return nullptr;
Expand Down

0 comments on commit 10fd060

Please sign in to comment.