PATCH GAS/ARM cleanup error messages.

Richard Earnshaw rearnsha@arm.com
Mon Jan 14 07:21:00 GMT 2002


The error messages printed by the arm port of gas are currently a mix of 
messages starting with a capital letter and with a lower-case letter.  I 
believe the GNU coding standard says that the latter should be used, so 
I've fixed the ones that start with a capital (except where it is required 
to do otherwise).

Also, we currently have a bug in that we mistakenly accept the bogus 
pseudo ops of the form

	str  reg, =<expr>

I've fixed that as well and added new functionality to the arm tests to 
allow testing for errors during assembly.

Finally I've fixed the error printing routine so that it will output the 
instruction that failed: IMO this makes it much easier for the user to 
diagnose what the problem is.

        * tc-arm.c (all error messages): Normalize capitalization of 
messages.

        * tc-arm.h (md_operand): Delete define.
        * tc-arm.c (in_my_get_expression): New static variable.
        (my_get_expression): Set and clear it.
        (md_operand): New function.  If called from my_get_expression
        put the error in inst.error.
        (output_inst): Now takes argument of instruction being assembled.
        Print it out with any error message.
        (do_ldst, do_ldstv4, thumb_load_store): Fault attempt to use a 
store
        with '=' syntax.
        (end_of_line): Don't update inst.error if it is already set.

and for the testsuite:

        * gas/arm/armv1-bad.s gas/arm/armv1-bad.l: New files.
        * gas/arm/arm.exp (run_error_test): New proc.
        (armv1-bad): New error test.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: gas-errs.patch
Type: text/x-patch
Size: 48159 bytes
Desc: gas-errs.patch
URL: <https://sourceware.org/pipermail/binutils/attachments/20020114/39adfe4f/attachment.bin>


More information about the Binutils mailing list