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 RFA: c99 inline patch for gcc 4.2


Ian Lance Taylor wrote:
+Note that since the first version of GCC to support C99 inline
+semantics is 4.3, earlier versions of GCC which accept this attribute
+effectively ignore it.  Its only effect is to disable warnings about
+using inline functions in C99 mode.

The phrase "effectively ignore it" sounds to me like it means that the compiler does the opposite of what the attribute would request.


Thus, I would suggest something like, "...earlier versions of GCC which accept this attribute effectively assume that it is always present, whether or not it is given explicitly. In version 4.2, the only effect of explicitly including it is to disable...."

+@item -fgnu89-inline
+@opindex fgnu89-inline
+The option @option{-fgnu89-inline} tells GCC to use the traditional
+GNU semantics for @code{inline} functions when in C99 mode.
+@xref{Inline,,An Inline Function is As Fast As a Macro}.  This option
+is accepted and ignored by GCC versions 4.1.3 up to but not including
+4.3.  In GCC versions 4.3 and later it changes the behavior of GCC in
+C99 mode.  Using this option is roughly equivalent to adding the
+@code{gnu_inline} function attribute to all inline functions
+(@pxref{Function Attributes}).
+
+The option @option{-fno-gnu89-inline} is not supported in versions of
+GCC before 4.3.  It will be supported only in C99 or gnu99 mode, not
+in C89 or gnu89 mode.

Similarly, "is accepted and ignored" creates (for me) a wrong impression here as well. Perhaps, "This option is the default in GCC versions..." or something like that? Or, alternately: "This option is accepted by GCC versions 4.1.3 and up. In GCC versions prior to 4.3, it is assumed present regardless of whether or not it is specified; in versions 4.3 and later it will not be. Using this option..."


Other than those two places, the documentation all looks quite clear to me.

(Although I do have a question: What does specifying -fgnu89-inline do to the warning messages? Does it disable in C99 mode, like specifying the attributes explicitly does?)

- Brooks


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