diff options
Diffstat (limited to 'gcc/testsuite/g++.dg/cpp0x')
-rw-r--r-- | gcc/testsuite/g++.dg/cpp0x/nontype7.C | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/cpp0x/nontype7.C b/gcc/testsuite/g++.dg/cpp0x/nontype7.C new file mode 100644 index 0000000..30c1d39 --- /dev/null +++ b/gcc/testsuite/g++.dg/cpp0x/nontype7.C @@ -0,0 +1,13 @@ +// PR c++/118632 +// { dg-do compile { target c++11 } } + +template<class T, T* = nullptr> +class Matrix {}; + +template<class T> +void operator*(Matrix<T>, int); + +int main() { + Matrix<int> m; + m * 42; +} |