/* We need to watch out for .end directives: We should in particular not
issue diagnostics for anything after an active one. */
- if (end_state == NULL)
+ if (ch == EOF)
+ end_state = NULL;
+ else if (end_state == NULL)
{
if ((state == 0 || state == 1)
&& (ch == '.'
#if defined TC_ARM && defined OBJ_ELF
/* We need to watch out for .symver directives. See the comment later
in this function. */
- if (symver_state == NULL)
+ if (ch == EOF)
+ symver_state = NULL;
+ else if (symver_state == NULL)
{
if ((state == 0 || state == 1)
&& strchr (tc_comment_chars, '@') != NULL
MRI mode or not. Unfortunately, since m68k MRI mode affects
the scrubber, that means that we need a special purpose
recognizer here. */
- if (mri_state == NULL)
+ if (ch == EOF)
+ mri_state = NULL;
+ else if (mri_state == NULL)
{
if ((state == 0 || state == 1)
&& ch == mri_pseudo[0])
}
else
{
- /* We've read the entire pseudo-op. mips_last_ch is
+ /* We've read the entire pseudo-op. mri_last_ch is
either '0' or '1' indicating whether to enter or
leave MRI mode. */
do_scrub_begin (mri_last_ch == '1');