summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/debug/template1.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.dg/debug/template1.C')
-rw-r--r--gcc/testsuite/g++.dg/debug/template1.C15
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/debug/template1.C b/gcc/testsuite/g++.dg/debug/template1.C
new file mode 100644
index 000000000..279b4b173
--- /dev/null
+++ b/gcc/testsuite/g++.dg/debug/template1.C
@@ -0,0 +1,15 @@
+// PR c++/5118
+
+template <int Count>
+class d
+{
+public:
+ d()
+ {
+ myInt = Count;
+ }
+ int myInt;
+ virtual ~d() {}
+};
+
+volatile d<5> instD;