diff options
-rw-r--r-- | gcc/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/testsuite/g++.dg/cpp0x/pr67238.C | 20 |
2 files changed, 25 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index df920a0..d84b6a8 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2015-11-26 Paolo Carlini <paolo.carlini@oracle.com> + + PR c++/67238 + * g++.dg/cpp0x/pr67238.C: New. + 2015-11-26 Martin Sebor <msebor@redhat.com> * g++.dg/pr67876.C: Remove duplicate content. diff --git a/gcc/testsuite/g++.dg/cpp0x/pr67238.C b/gcc/testsuite/g++.dg/cpp0x/pr67238.C new file mode 100644 index 0000000..606a21e --- /dev/null +++ b/gcc/testsuite/g++.dg/cpp0x/pr67238.C @@ -0,0 +1,20 @@ +// { dg-do compile { target c++11 } } +// { dg-options "-g" } + +template<class F, class... A> +void +g(F&&, A&&...) +{} + +template<class... A> +auto +h(A&&... a) -> decltype(g(0, g<decltype(a)>(a)...)) +{ + return g([]{}, a...); +} + +int +main() +{ + h(); +} |