Internal error at gas/expr.c:1814

Message ID Y+QsUGAY7LQw0zQu@squeak.grove.modra.org
State Repeat Merge
Headers
Series Internal error at gas/expr.c:1814 |

Checks

Context Check Description
snail/binutils-gdb-check warning Git am fail log

Commit Message

Alan Modra Feb. 8, 2023, 11:12 p.m. UTC
  This is the assertion
  know (*input_line_pointer != ' ');
after calling operand.

The usual exit from operand calls SKIP_ALL_WHITESPACE.

	* expr.c (operand): Call SKIP_ALL_WHITESPACE after call to expr.
  

Patch

diff --git a/gas/expr.c b/gas/expr.c
index 794be6f09d8..189236bec6d 100644
--- a/gas/expr.c
+++ b/gas/expr.c
@@ -996,7 +996,7 @@  operand (expressionS *expressionP, enum expr_mode mode)
 	}	    
       else
 	input_line_pointer++;
-      SKIP_WHITESPACE ();
+      SKIP_ALL_WHITESPACE ();
       /* Here with input_line_pointer -> char after "(...)".  */
       return segment;