summaryrefslogtreecommitdiff
path: root/gcc/config/sparc/sysv4.h
diff options
context:
space:
mode:
authorbrendan <brendan@138bc75d-0d04-0410-961f-82ee72b054a4>1995-02-13 06:11:50 +0000
committerbrendan <brendan@138bc75d-0d04-0410-961f-82ee72b054a4>1995-02-13 06:11:50 +0000
commit48fcaaad38b21594c59816060dcf27cf852a0184 (patch)
tree595ab4430222b52c0ab8fa1497f21b43a9f09e0a /gcc/config/sparc/sysv4.h
parent39ba8f06c914a76d9dd0ef3aef88b0ebe8bcdcc3 (diff)
downloadgcc-48fcaaad38b21594c59816060dcf27cf852a0184.tar.gz
Sun Feb 12 20:20:28 1995 Brendan Kehoe (brendan@lisa.cygnus.com)
* config/sparc/sysv4.h (ASM_OUTPUT_SECTION_NAME): Check to make sure DECL is non-null before trying to reference it. * config/mips/elf64.h (ASM_OUTPUT_SECTION_NAME): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@8915 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/sparc/sysv4.h')
-rw-r--r--gcc/config/sparc/sysv4.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/config/sparc/sysv4.h b/gcc/config/sparc/sysv4.h
index 96035f3ddc4..8d715014ac7 100644
--- a/gcc/config/sparc/sysv4.h
+++ b/gcc/config/sparc/sysv4.h
@@ -183,9 +183,9 @@ do { ASM_OUTPUT_ALIGN ((FILE), Pmode == SImode ? 2 : 3); \
#undef ASM_OUTPUT_SECTION_NAME /* Override svr4.h's definition. */
#define ASM_OUTPUT_SECTION_NAME(FILE, DECL, NAME) \
do { \
- if (TREE_CODE (DECL) == FUNCTION_DECL) \
+ if ((DECL) && TREE_CODE (DECL) == FUNCTION_DECL) \
fprintf (FILE, ".section\t\"%s\",#alloc,#execinstr\n", (NAME)); \
- else if (TREE_READONLY (DECL)) \
+ else if ((DECL) && TREE_READONLY (DECL)) \
fprintf (FILE, ".section\t\"%s\",#alloc\n", (NAME)); \
else \
fprintf (FILE, ".section\t\"%s\",#alloc,#write\n", (NAME)); \