diff options
author | Jason Merrill <jason@yorick.cygnus.com> | 1998-03-18 12:42:05 +0000 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 1998-03-18 07:42:05 -0500 |
commit | 74ef3b26f3efc6b3c36aaf2bad21f035c8aa3ad1 (patch) | |
tree | 30f1e06b76727fd7ef4a2e92bf309ede00f78a06 | |
parent | ad3212931059fbf2c069c11851c587a4e86380b3 (diff) | |
download | gcc-74ef3b26f3efc6b3c36aaf2bad21f035c8aa3ad1.zip gcc-74ef3b26f3efc6b3c36aaf2bad21f035c8aa3ad1.tar.gz gcc-74ef3b26f3efc6b3c36aaf2bad21f035c8aa3ad1.tar.bz2 |
decl.c (make_implicit_typename): Only change the type of a TYPENAME_TYPE.
* decl.c (make_implicit_typename): Only change the type of a
TYPENAME_TYPE.
From-SVN: r18668
-rw-r--r-- | gcc/cp/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/cp/decl.c | 5 |
2 files changed, 8 insertions, 2 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 723c5a2..b8269f3 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,8 @@ +Wed Mar 18 12:41:43 1998 Jason Merrill <jason@yorick.cygnus.com> + + * decl.c (make_implicit_typename): Only change the type of a + TYPENAME_TYPE. + Wed Mar 18 10:09:51 1998 Mark Mitchell <mmitchell@usa.net> * semantics.c: New file, containing routines to perform the diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index 4c33191..80fc959 100644 --- a/gcc/cp/decl.c +++ b/gcc/cp/decl.c @@ -4592,8 +4592,9 @@ make_implicit_typename (context, t) } else retval = make_typename_type (context, DECL_NAME (t)); - - TREE_TYPE (retval) = TREE_TYPE (t); + + if (TREE_CODE (retval) == TYPENAME_TYPE) + TREE_TYPE (retval) = TREE_TYPE (t); return retval; } |