From: Jie Zhang Date: Tue, 23 May 2006 06:01:12 +0000 (+0000) Subject: * config/tc-bfin.c (bfin_start_line_hook): Bump line counters X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=9db51b6b2baf067ca80ebe419b3d7b8fbacb0660;p=pf3gnuchains%2Fpf3gnuchains3x.git * config/tc-bfin.c (bfin_start_line_hook): Bump line counters if needed. --- diff --git a/gas/ChangeLog b/gas/ChangeLog index 073a128363..5232ad47ca 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,5 +1,10 @@ 2006-05-23 Jie Zhang + * config/tc-bfin.c (bfin_start_line_hook): Bump line counters + if needed. + +2006-05-23 Jie Zhang + * config/bfin-defs.h (bfin_equals): Remove declaration. * config/bfin-parse.y (asm_1): Remove "expr ASSIGN expr". * config/tc-bfin.c (bfin_name_is_register): Remove. diff --git a/gas/config/tc-bfin.c b/gas/config/tc-bfin.c index f70a94dc94..03e733a0de 100644 --- a/gas/config/tc-bfin.c +++ b/gas/config/tc-bfin.c @@ -834,9 +834,14 @@ bfin_start_line_hook () char *c1, *label_name; symbolS *line_label; char *c = input_line_pointer; + int cr_num = 0; while (ISSPACE (*c)) - c++; + { + if (*c == '\n') + cr_num++; + c++; + } /* Look for Loop_Begin or Loop_End statements. */ @@ -902,6 +907,12 @@ bfin_start_line_hook () c1 = c; while (ISALPHA (*c) || ISDIGIT (*c) || *c == '_') c++; + if (input_line_pointer[-1] == '\n') + bump_line_counters (); + + while (cr_num--) + bump_line_counters (); + input_line_pointer = c; if (maybe_end) {