[PATCH 33/34] gas: fold is_end_of_line[] into lex_type[]

Alan Modra amodra@gmail.com
Wed Feb 19 23:45:44 GMT 2025


On Wed, Feb 19, 2025 at 04:40:44PM +0100, Jan Beulich wrote:
> --- a/gas/read.c
> +++ b/gas/read.c
> @@ -6800,7 +6774,7 @@ _find_end_of_line (char *s, int mri_stri
>    char inquote = '\0';
>    int inescape = 0;
>  
> -  while (!is_end_of_line[(unsigned char) *s]
> +  while (!is_end_of_stmt (*s)
>  	 || (inquote && !ISCNTRL (*s))
>  	 || (inquote == '\'' && flag_mri)
>  #ifdef TC_EOL_IN_INSN
> @@ -6809,7 +6783,7 @@ _find_end_of_line (char *s, int mri_stri
>  	 /* PR 6926:  When we are parsing the body of a macro the sequence
>  	    \@ is special - it refers to the invocation count.  If the @
>  	    character happens to be registered as a line-separator character
> -	    by the target, then the is_end_of_line[] test above will have
> +	    by the target, then the is_end_of_line() test above will have

is_end_of_stmt

>  	    returned true, but we need to ignore the line separating
>  	    semantics in this particular case.  */
>  	 || (in_macro && inescape && *s == '@')

-- 
Alan Modra


More information about the Binutils mailing list