aboutsummaryrefslogtreecommitdiff
path: root/gas/config
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1993-07-15 22:01:27 +0000
committerIan Lance Taylor <ian@airs.com>1993-07-15 22:01:27 +0000
commit5276e361db1a5ed61deb65fe1b70e5abbd70a5c1 (patch)
treeba5810f1ebb0b88bc942444a2e1a363a8ee35da6 /gas/config
parentccdc578f572f5b04b7f27ba35555a047ae67bc42 (diff)
downloadfsf-binutils-gdb-5276e361db1a5ed61deb65fe1b70e5abbd70a5c1.zip
fsf-binutils-gdb-5276e361db1a5ed61deb65fe1b70e5abbd70a5c1.tar.gz
fsf-binutils-gdb-5276e361db1a5ed61deb65fe1b70e5abbd70a5c1.tar.bz2
* config/obj-ecoff.c (ecoff_frob_file): Discard all open scopes,
with a warning.
Diffstat (limited to 'gas/config')
-rw-r--r--gas/config/obj-ecoff.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/gas/config/obj-ecoff.c b/gas/config/obj-ecoff.c
index 69ecbc2..30d292f 100644
--- a/gas/config/obj-ecoff.c
+++ b/gas/config/obj-ecoff.c
@@ -4415,6 +4415,7 @@ ecoff_frob_file ()
tag_t *ptag;
tag_t *ptag_next;
efdr_t *fil_ptr;
+ int end_warning;
efdr_t *hold_file_ptr;
proc_t * hold_proc_ptr;
bfd_vma addr;
@@ -4454,11 +4455,21 @@ ecoff_frob_file ()
/* Output an ending symbol for all the files. We have to do this
here for the last file, so we may as well do it for all of the
files. */
+ end_warning = 0;
for (fil_ptr = first_file;
fil_ptr != (efdr_t *) NULL;
fil_ptr = fil_ptr->next_file)
{
cur_file_ptr = fil_ptr;
+ while (cur_file_ptr->cur_scope->prev != (scope_t *) NULL)
+ {
+ cur_file_ptr->cur_scope = cur_file_ptr->cur_scope->prev;
+ if (! end_warning)
+ {
+ as_warn ("Missing .end or .bend at end of file");
+ end_warning = 1;
+ }
+ }
(void) add_ecoff_symbol ((const char *) NULL,
st_End, sc_Text,
(symbolS *) NULL,