diff options
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.pt/dynarray.C')
-rw-r--r-- | gcc/testsuite/g++.old-deja/g++.pt/dynarray.C | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/dynarray.C b/gcc/testsuite/g++.old-deja/g++.pt/dynarray.C new file mode 100644 index 000000000..7376f9165 --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.pt/dynarray.C @@ -0,0 +1,22 @@ +// { dg-do assemble } +// { dg-options "" } +// Origin: Theo Papadopoulo <Theodore.Papadopoulo@sophia.inria.fr> + +inline const unsigned& f(unsigned const& a) { + return a; +} + +template <class T> +void +g(const unsigned n) +{ + double D[f(n)]; +} + +template <class T,class U> +void g(unsigned const int) { } + +int main() +{ + g<double>(18); +} |