constexpr.c (literal_type_p): Return true for void type in C++14.
authorMarek Polacek <polacek@redhat.com>
Mon, 1 Dec 2014 15:26:10 +0000 (15:26 +0000)
committerMarek Polacek <mpolacek@gcc.gnu.org>
Mon, 1 Dec 2014 15:26:10 +0000 (15:26 +0000)
commite42c407c8ad2b2bf30fdfab1f7cb6948f1949f38
tree0cafcc47e67ab0a33504262784e400ad017401b1
parent7a1811342e2bf412fa3ad4c023342d4aca47cb54
constexpr.c (literal_type_p): Return true for void type in C++14.

* constexpr.c (literal_type_p): Return true for void type in C++14.

* g++.dg/cpp0x/constexpr-function2.C: Limit dg-error to C++11.
* g++.dg/cpp0x/constexpr-neg1.C: Likewise.
* g++.dg/cpp1y/constexpr-void1.C: New test.

From-SVN: r218220
gcc/cp/ChangeLog
gcc/cp/constexpr.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/cpp0x/constexpr-function2.C
gcc/testsuite/g++.dg/cpp0x/constexpr-neg1.C
gcc/testsuite/g++.dg/cpp1y/constexpr-void1.C [new file with mode: 0644]