]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
tree.c (mapcar): When dealing with a DECL, use it's constant value, if any.
authorMark Mitchell <mmitchel@gcc.gnu.org>
Tue, 24 Mar 1998 16:13:12 +0000 (16:13 +0000)
committerMark Mitchell <mmitchel@gcc.gnu.org>
Tue, 24 Mar 1998 16:13:12 +0000 (16:13 +0000)

* tree.c (mapcar): When dealing with a DECL, use it's constant
value, if any.
* pt.c (lookup_template_class): Don't mangle the names of template
classes whose arguments are unknown.
* pt.c (tsubst_expr): Handle GOTO_STMT correctly.

From-SVN: r18805

gcc/testsuite/g++.old-deja/g++.pt/explicit68.C [new file with mode: 0644]

diff --git a/gcc/testsuite/g++.old-deja/g++.pt/explicit68.C b/gcc/testsuite/g++.old-deja/g++.pt/explicit68.C
new file mode 100644 (file)
index 0000000..0f7d08f
--- /dev/null
@@ -0,0 +1,22 @@
+template <bool B>
+struct S
+{
+  static void g();
+};
+
+template <bool B>
+void g();
+
+template<unsigned Length>
+void f()
+{
+  const bool b = true;
+  g<b>();
+  const bool b1 = (Length == 2);
+  S<b1>::g();
+}
+
+void h()
+{
+  f<3>();
+}