This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Patch, fortran] Fix PR19101 missing & in character continuation not caught


Steve,

What about something like:


void gfc_gobble_whitespace (void) { static bool seen_tab; locus old_loc; int c; do { old_loc = gfc_current_locus; c = gfc_next_char_literal (0); if (!gfc_option.flag_tabs && c == '\t' && !seen_tab) { gfc_warning_now ("Nonconforming tab character at %C; "

"repetitions will be ignored.");

          seen_tab = true;
       }
   }
 while (gfc_is_whitespace (c));

 gfc_current_locus = old_loc;
}

But, this can't deal with the fixed-form, column 1, issue.


It seems to me that a one-off warning to go check the source would be the way to do it.

Paul


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]