8sa1-gcc/gcc/testsuite/g++.dg/cpp0x/constexpr-85553.C
Jakub Jelinek b2b1ea3455 re PR c++/85553 (cannot list-initialize a variable of type std::nullptr_t)
PR c++/85553
	* init.c (build_zero_init_1): For zero initialization of
	NULLPTR_TYPE_P type use build_int_cst directly.

	* g++.dg/cpp0x/Wzero-as-null-pointer-constant-3.C: Add dg-bogus
	directive.
	* g++.dg/cpp0x/constexpr-85553.C: New test.

From-SVN: r259728
2018-04-27 22:29:12 +02:00

5 lines
108 B
C

// PR c++/85553
// { dg-do compile { target c++11 } }
using T = decltype(nullptr);
const constexpr T foo{};