[ACCEPTED]-what is meanging of gcc option "-fmessage-length"?-compiler-construction

Accepted answer
Score: 41

I didnt find it in GCC Command-Line Options.

That's 17 because you're looking at "a modified version of the Command-Line Options section of the GCC Manual."

This is the official list of all possible GCC command-line options, which leads 16 to this section: "3.7 Options to Control Diagnostic Messages Formatting". This is what the section 15 has to say:

3.7 Options to Control Diagnostic Messages Formatting

Traditionally, diagnostic messages 14 have been formatted irrespective of the 13 output device's aspect (e.g. its width, ...). You 12 can use the options described below to 11 control the formatting algorithm for diagnostic 10 messages, e.g. how many characters per line, how 9 often source location information should 8 be reported. Note that some language front 7 ends may not honor these options.

-fmessage-length=n

Try to 6 format error messages so that they fit on 5 lines of about n characters. The default 4 is 72 characters for g++ and 0 for the rest 3 of the front ends supported by GCC. If n 2 is zero, then no line-wrapping is done; each 1 error message appears on a single line.

...

Score: 10

man page for gcc says

-fmessage-length=n
       Try to format error messages so that they fit on lines of about n characters.  The default is 72 characters for g++ and 0 for the rest of the front ends supported by GCC.  If n is
       zero, then no line-wrapping will be done; each error message will appear on a single line.

Just a formatting option 1 for error messages.

More Related questions