From 6d89b990a536d3ec4c3edfc1126c0abb1bab1251 Mon Sep 17 00:00:00 2001 From: Mark Mitchell Date: Wed, 11 Mar 1998 23:34:32 +0000 Subject: [PATCH] dbxout.c (dbxout_type_methods): Only treat TYPE_METHODS as a TREE_VEC if that's what it really is. * dbxout.c (dbxout_type_methods): Only treat TYPE_METHODS as a TREE_VEC if that's what it really is. From-SVN: r18487 --- gcc/ChangeLog | 5 ++ gcc/dbxout.c | 2 +- gcc/testsuite/g++.old-deja/g++.other/debug1.C | 48 +++++++++++++++++++ .../g++.old-deja/g++.other/new-init.C | 7 +++ 4 files changed, 61 insertions(+), 1 deletion(-) create mode 100644 gcc/testsuite/g++.old-deja/g++.other/debug1.C create mode 100644 gcc/testsuite/g++.old-deja/g++.other/new-init.C diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 39c73e7f20f..3c87446daca 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +1998-03-11 Mark Mitchell + + * dbxout.c (dbxout_type_methods): Only treat TYPE_METHODS as a + TREE_VEC if that's what it really is. + Wed Mar 11 15:16:01 1998 Michael Meissner * {haifa-,}sched.c (rank_for_schedule): Only take void * arguments diff --git a/gcc/dbxout.c b/gcc/dbxout.c index 7fa9139b9d8..101574f2750 100644 --- a/gcc/dbxout.c +++ b/gcc/dbxout.c @@ -824,7 +824,7 @@ dbxout_type_methods (type) sprintf(formatted_type_identifier_length, "%d", type_identifier_length); - if (TREE_CODE (methods) == FUNCTION_DECL) + if (TREE_CODE (methods) != TREE_VEC) fndecl = methods; else if (TREE_VEC_ELT (methods, 0) != NULL_TREE) fndecl = TREE_VEC_ELT (methods, 0); diff --git a/gcc/testsuite/g++.old-deja/g++.other/debug1.C b/gcc/testsuite/g++.old-deja/g++.other/debug1.C new file mode 100644 index 00000000000..84858957a79 --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.other/debug1.C @@ -0,0 +1,48 @@ +// Build don't link: +// Special g++ Options: -g + +typedef unsigned int size_t; + + +struct dummy { }; + +struct arrrrrgh { }; + + +template +struct whyyyyyyy { }; + + + + +template +struct grrrrrrrr { }; + + +template +class no_future +{ +public: + + + template + no_future(const grrrrrrrr*,S>& man ) { } + + ~no_future( ) { } + +private: + + + no_future(const no_future&); + no_future& operator=(const no_future&); +}; + + +int main( ) +{ + grrrrrrrr*> man; + + no_future here(man); + + return 0; +} diff --git a/gcc/testsuite/g++.old-deja/g++.other/new-init.C b/gcc/testsuite/g++.old-deja/g++.other/new-init.C new file mode 100644 index 00000000000..fff2f63595e --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.other/new-init.C @@ -0,0 +1,7 @@ +// Build don't link: + +void f() +{ + new int = 1; +} +