aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/decl.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/fortran/decl.cc')
-rw-r--r--gcc/fortran/decl.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/fortran/decl.cc b/gcc/fortran/decl.cc
index b640051..0f9b2ce 100644
--- a/gcc/fortran/decl.cc
+++ b/gcc/fortran/decl.cc
@@ -423,7 +423,8 @@ match_data_constant (gfc_expr **result)
data-pointer-initialization compatible (7.5.4.6) with the initial
data target; the data statement object is initially associated
with the target. */
- if ((*result)->symtree->n.sym->attr.save
+ if ((*result)->symtree
+ && (*result)->symtree->n.sym->attr.save
&& (*result)->symtree->n.sym->attr.target)
return m;
gfc_free_expr (*result);