[03/45] c++: source position of lambda captures [PR84471]

Message ID 20230807111029.2320238-4-arsen@aarsen.me
State New
Headers
Series Synchronize shared build infrastructure with GCC tree |

Commit Message

Arsen Arsenović Aug. 7, 2023, 11:07 a.m. UTC
  From: Jason Merrill <jason@redhat.com>

include/ChangeLog:

	* ansidecl.h (ATTRIBUTE_WARN_UNUSED_RESULT): Add __.
---
 include/ansidecl.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Comments

Jason Merrill Aug. 10, 2023, 9:48 p.m. UTC | #1
On 8/7/23 07:07, Arsen Arsenović wrote:
> From: Jason Merrill <jason@redhat.com>

This looks strange outside of the context of https://gcc.gnu.org/r13-4812 :)

You will want to adjust the commit subject line to reflect that it's now 
just the include change.

> include/ChangeLog:
> 
> 	* ansidecl.h (ATTRIBUTE_WARN_UNUSED_RESULT): Add __.
> ---
>   include/ansidecl.h | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/include/ansidecl.h b/include/ansidecl.h
> index d94145d1313..39375e17156 100644
> --- a/include/ansidecl.h
> +++ b/include/ansidecl.h
> @@ -279,7 +279,7 @@ So instead we use the macro below and test it against specific values.  */
>   /* Attribute `warn_unused_result' was valid as of gcc 3.3.  */
>   #ifndef ATTRIBUTE_WARN_UNUSED_RESULT
>   # if GCC_VERSION >= 3003
> -#  define ATTRIBUTE_WARN_UNUSED_RESULT __attribute__ ((warn_unused_result))
> +#  define ATTRIBUTE_WARN_UNUSED_RESULT __attribute__ ((__warn_unused_result__))
>   # else
>   #  define ATTRIBUTE_WARN_UNUSED_RESULT
>   # endif
  

Patch

diff --git a/include/ansidecl.h b/include/ansidecl.h
index d94145d1313..39375e17156 100644
--- a/include/ansidecl.h
+++ b/include/ansidecl.h
@@ -279,7 +279,7 @@  So instead we use the macro below and test it against specific values.  */
 /* Attribute `warn_unused_result' was valid as of gcc 3.3.  */
 #ifndef ATTRIBUTE_WARN_UNUSED_RESULT
 # if GCC_VERSION >= 3003
-#  define ATTRIBUTE_WARN_UNUSED_RESULT __attribute__ ((warn_unused_result))
+#  define ATTRIBUTE_WARN_UNUSED_RESULT __attribute__ ((__warn_unused_result__))
 # else
 #  define ATTRIBUTE_WARN_UNUSED_RESULT
 # endif