This is the mail archive of the gcc-bugs@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]

[Bug middle-end/84034] incomplete warning message with dos line endings


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84034

--- Comment #1 from Bernd Edlinger <bernd.edlinger at hotmail dot de> ---
it is acutally a problem with the colorizer:

gcc -fdiagnostics-color=always -Wall -S test.c 2> xx

cat xx
test.c: In function ‘test’:
test.c:5:20: warning: suggest parentheses around ‘&&’ within ‘||’
[-Wparentheses]

       ~~~~~~~~~~~~~^~~
       f)
       ~             

cat xx|tr "\r" " "
test.c: In function ‘test’:
test.c:5:20: warning: suggest parentheses around ‘&&’ within ‘||’
[-Wparentheses]
       (d && b > e) && 
       ~~~~~~~~~~~~~^~~
       f) 
       ~             


so the missing line is quickly overprinted, because the color is swithed off
between CR and LF, by replacing CR with SPACE the print out looks correct.

How about replacing all CR with SPACE (like the TAB is also done IIRC)?

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