re PR libstdc++/68430 (std::is_constructible<T>::value == true for unconstructible...
authorVille Voutilainen <ville.voutilainen@gmail.com>
Mon, 18 Dec 2017 18:46:30 +0000 (20:46 +0200)
committerVille Voutilainen <ville@gcc.gnu.org>
Mon, 18 Dec 2017 18:46:30 +0000 (20:46 +0200)
PR libstdc++/68430

* testsuite/20_util/is_constructible/68430.cc: New.

From-SVN: r255785

libstdc++-v3/ChangeLog
libstdc++-v3/testsuite/20_util/is_constructible/68430.cc [new file with mode: 0644]

index 1275ea5e85f7e33e7266472eecd51000dd10a300..08096d10e7cb8bb8cde162018fe20ba7bdd4f212 100644 (file)
@@ -1,3 +1,8 @@
+2017-12-18  Ville Voutilainen  <ville.voutilainen@gmail.com>
+
+       PR libstdc++/68430
+       * testsuite/20_util/is_constructible/68430.cc: New.
+
 2017-12-16  Martin Sebor  <msebor@redhat.com>
 
        PR tree-optimization/83239
diff --git a/libstdc++-v3/testsuite/20_util/is_constructible/68430.cc b/libstdc++-v3/testsuite/20_util/is_constructible/68430.cc
new file mode 100644 (file)
index 0000000..3f880b3
--- /dev/null
@@ -0,0 +1,6 @@
+// { dg-do compile { target c++11 } }
+
+#include <type_traits>
+
+template<class T> struct Foo { Foo(T = nullptr) {} };
+static_assert(!std::is_constructible<Foo<int>>::value, "");