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] Add std::is_constant_evaluated wrapper around __builtin_is_constant_evaluated


On 11/12/18 17:35 +0100, Jakub Jelinek wrote:
Hi!

The following patch adds std::is_constant_evaluated to the library.

Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?
(relies on the previously posted C++ FE patch).

2018-12-11  Jakub Jelinek  <jakub@redhat.com>

	P0595R2 - is_constant_evaluated
	* include/bits/c++config (_GLIBCXX_HAVE_BUILTIN_IS_CONSTANT_EVALUATED):
	Define if __builtin_is_constant_evaluated is available.
	* include/std/type_traits (std::is_constant_evaluated): New constexpr
	inline function.
	* testsuite/20_util/is_constant_evaluated/1.cc: New test.
	* testsuite/20_util/is_constant_evaluated/noexcept.cc: New test.

OK, thanks.



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