From 54e1d3a6a9dd0caab503807de6fb85ae1a1db0de Mon Sep 17 00:00:00 2001 From: Mark Mitchell Date: Fri, 4 Aug 2000 20:24:47 +0000 Subject: [PATCH] Minor tweaks From-SVN: r35493 --- gcc/extend.texi | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/gcc/extend.texi b/gcc/extend.texi index 8d047f664fc..4a8c87c2d73 100644 --- a/gcc/extend.texi +++ b/gcc/extend.texi @@ -203,7 +203,7 @@ handled. For example: does not work the same way as: @example -inline int foo(a) @{ int b = a; return b + 3; @} +inline int foo(int a) @{ int b = a; return b + 3; @} @end example @noindent @@ -213,19 +213,9 @@ run earlier in the case of the macro than in the case of the function. These considerations mean that it is probably a bad idea to use statement-expressions of this form in header files that are designed to -work with C++. Note that the GNU C Library does contain header files -using statement-expressions, and that these definitions make the library -technically non-conforming. For example, when optimization is turned -on, - -@example -string a, b; -printf("%c", toupper((a+b).c_str()[0])); -@end example - -@noindent -will result in the destructor for the temporary created for @code{a+b} -being run earlier than it should be. +work with C++. (Note that some versions of the GNU C Library contained +header files using statement-expression that lead to precisely this +bug.) @node Local Labels @section Locally Declared Labels -- 2.30.2