· Parameter -Wpedantic is available in newer gcc with a slight different meaning of -pedantic. Testing on my machine, though, it doesn't make a difference to F3. I'll change that in the Makefile to simplify everyone's life. Could you provide the link to the referred manual/section? I couldn't easily find it. Here is a truncated example from the ARM port of gcc: % gcc -Q -mabi=2 --help=target -c The following options are target specific: mabi= 2 -mabort-on-noreturn [disabled] -mapcs [disabled] The output is sensitive to the effects of previous command- line options, so for example it is possible to find out which optimizations are enabled at -O2 by. I use it all the time in my coding. The -ansi flag is equivalent to -std=cAs noted, it turns off some extensions of GCC. Adding -pedantic turns off more extensions and generates more warnings. For example, if you have a string literal longer than characters, then -pedantic warns about that because it exceeds the minimum limit required by the C89 standard.
GCC Release Series Changes, New Features, and Fixes Caveats. The installation manual contains more information about requirements to build GCC. The new option -Wpedantic is an alias for -pedantic, which is now deprecated. The forms -Wno-pedantic, -Werror=pedantic. Clang Compiler User's Manual These extensions are provided to be compatible with the GCC, Microsoft, and other popular compilers as well as to improve functionality through Clang-specific features. The Clang driver and language features are intentionally designed to be as compatible with the GNU GCC compiler as reasonably possible, easing. Parameter -Wpedantic is available in newer gcc with a slight different meaning of -pedantic. Testing on my machine, though, it doesn't make a difference to F3. I'll change that in the Makefile to simplify everyone's life. Could you provide the link to the referred manual/section? I couldn't easily find it.
From the gcc manual -Wpedantic' '-pedantic' Issue all the warnings demanded by strict ISO C and ISO C++; reject all programs that use forbidden extensions, From Fortran , Conformance A processor conforms to this document if. GCC can warn you if you are using identifiers which have not been normalized; this option controls that warning. There are four levels of warning that GCC supports. The default is -Wnormalized=nfc, which warns about any identifier which is not in the ISO “C” normalized form, NFC. Thus, code that is not maximally portable to C90 will generate warnings when compiled with -pedantic under GCC 4.x, but won't generate the same warnings with GCC 5.x unless the construct is also not portable to all C11 compilers — unless it violates one of the C11 compile-time limits too. The -pedantic flag has its uses.
0コメント