Skip to content
Snippets Groups Projects
Unverified Commit 5467f5b5 authored by Jonathan Wakely's avatar Jonathan Wakely Committed by Jonathan Wakely
Browse files

ginclude: stdalign.h should define __xxx_is_defined macros for C++

The __alignas_is_defined macro has been required by C++ since C++11, and
C++ Library DR 4036 clarified that __alignof_is_defined should be
defined too. The whole <stdalign.h> header was deprecated for C++23 (see
LWG 3827) and is likely to be removed for C++26 (see P3348), but we can
deal with that later.

The macros alignas and alignof should not be defined, as they're
keywords in C++.

gcc/ChangeLog:

	* ginclude/stdalign.h (__alignas_is_defined): Define for C++.
	(__alignof_is_defined): Likewise.

libstdc++-v3/ChangeLog:

	* testsuite/18_support/headers/cstdalign/macros.cc: New test.
parent f342d66d
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment