summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>2001-03-15 03:37:14 +0000
committermmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>2001-03-15 03:37:14 +0000
commit35ccf3b05dece0d6de2fbfb098d5a7a77926f926 (patch)
treeaa7a4a8a4d9bbb67d0b4dee61782357ae31df425
parent0e8e37b2e8d034c84c53890b9b186bd8121804a5 (diff)
downloadppe42-gcc-35ccf3b05dece0d6de2fbfb098d5a7a77926f926.tar.gz
ppe42-gcc-35ccf3b05dece0d6de2fbfb098d5a7a77926f926.zip
* decl.c (cp_make_fnname_decl): Set DECL_IGNORED_P on __FUNCTION__
and its ilk. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@40485 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/cp/ChangeLog5
-rw-r--r--gcc/cp/decl.c1
-rw-r--r--gcc/testsuite/g++.old-deja/g++.other/fnname1.C8
3 files changed, 14 insertions, 0 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index c02b2412698..4258b7e8681 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,5 +1,10 @@
2001-03-14 Mark Mitchell <mark@codesourcery.com>
+ * decl.c (cp_make_fnname_decl): Set DECL_IGNORED_P on __FUNCTION__
+ and its ilk.
+
+2001-03-14 Mark Mitchell <mark@codesourcery.com>
+
* class.c (build_clone): Use COPY_DECL_RTL, DECL_RTL_SET_P, etc.
* cp-tree.h (DECL_IN_MEMORY_P): Likewise.
* decl.c (duplicate_decls): Likewise.
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c
index f917fc86a19..8a5857a506b 100644
--- a/gcc/cp/decl.c
+++ b/gcc/cp/decl.c
@@ -6609,6 +6609,7 @@ cp_make_fname_decl (id, name, type_dep)
DECL_SOURCE_LINE (decl) = 0;
DECL_ARTIFICIAL (decl) = 1;
DECL_IN_SYSTEM_HEADER (decl) = 1;
+ DECL_IGNORED_P (decl) = 1;
pushdecl (decl);
if (processing_template_decl)
decl = push_template_decl (decl);
diff --git a/gcc/testsuite/g++.old-deja/g++.other/fnname1.C b/gcc/testsuite/g++.old-deja/g++.other/fnname1.C
new file mode 100644
index 00000000000..8fcf07f08ef
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.other/fnname1.C
@@ -0,0 +1,8 @@
+// Build don't run:
+// Origin: Loren James Rittle <rittle@latour.rsch.comm.mot.com>
+// Special g++ Options: -g
+
+int main ()
+{
+ const char *s = __FUNCTION__;
+}
OpenPOWER on IntegriCloud