[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: XScale assembler 2.11.2 bug when using .rept & .endr psuedo-ops
From: |
Nick Clifton |
Subject: |
Re: XScale assembler 2.11.2 bug when using .rept & .endr psuedo-ops |
Date: |
12 Oct 2001 09:51:24 +0100 |
User-agent: |
Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 |
Hi George,
> I have observed 2 problems when using .rept and .endr psuedo ops
> with 2.11.2.
>
> 1. They cause the assembler to error when using literals
Please could you provide an example of this.
> 2. Using the .endr without a .rept errors as "Unknown
> psuedo-op .endr"
Well, it is only valid in the context of a .rept/.irc/.irp pseudo op,
but it is easy enough to fix, so I am going to apply the patch below
to provide a more helpful warning message.
Cheers
Nick
2001-10-12 Nick Clifton <address@hidden>
* read.c (s_bad_endr): New function. Issues a warning message
about a bad use of the .rept pseudo op.
(po_table[]): Add .endr.
* read.h: Prototype s_bad_endr.
Index: gas/read.c
===================================================================
RCS file: /cvs/src/src/gas/read.c,v
retrieving revision 1.48
diff -p -r1.48 read.c
*** read.c 2001/10/05 10:53:00 1.48
--- read.c 2001/10/12 08:50:46
*************** static const pseudo_typeS potable[] = {
*** 315,320 ****
--- 315,321 ----
{"endc", s_endif, 0},
{"endfunc", s_func, 1},
{"endif", s_endif, 0},
+ {"endr", s_bad_endr, 0},
/* endef */
{"equ", s_set, 0},
{"equiv", s_set, 1},
*************** s_purgem (ignore)
*** 2688,2693 ****
--- 2689,2704 ----
while (*input_line_pointer++ == ',');
--input_line_pointer;
+ demand_empty_rest_of_line ();
+ }
+
+ /* Handle the .rept pseudo-op. */
+
+ void
+ s_bad_endr (ignore)
+ int ignore ATTRIBUTE_UNUSED;
+ {
+ as_warn (_(".endr encountered without preceeding .rept, .irc, or .irp"));
demand_empty_rest_of_line ();
}
Index: gas/read.h
===================================================================
RCS file: /cvs/src/src/gas/read.h,v
retrieving revision 1.13
diff -p -r1.13 read.h
*** read.h 2001/07/09 08:19:17 1.13
--- read.h 2001/10/12 08:50:46
*************** extern void s_align_bytes PARAMS ((int a
*** 139,144 ****
--- 139,145 ----
extern void s_align_ptwo PARAMS ((int));
extern void s_app_file PARAMS ((int));
extern void s_app_line PARAMS ((int));
+ extern void s_bad_endr PARAMS ((int));
extern void s_comm PARAMS ((int));
extern void s_data PARAMS ((int));
extern void s_desc PARAMS ((int));