diff options
author | Janus Weil <janus@gcc.gnu.org> | 2016-11-30 14:23:17 +0100 |
---|---|---|
committer | Janus Weil <janus@gcc.gnu.org> | 2016-11-30 14:23:17 +0100 |
commit | d5c50b024fbfe4255270fa4c7845b222466d2e79 (patch) | |
tree | 4cc5b48fcde522d26fe076393441cdeacef4da6a /gcc/fortran/primary.c | |
parent | 4b498f721ef25cb4cd43b4349271987cb25ae357 (diff) | |
download | gcc-d5c50b024fbfe4255270fa4c7845b222466d2e79.zip gcc-d5c50b024fbfe4255270fa4c7845b222466d2e79.tar.gz gcc-d5c50b024fbfe4255270fa4c7845b222466d2e79.tar.bz2 |
re PR fortran/78593 (ICE in gfc_match_varspec, at fortran/primary.c:2053)
2016-11-30 Janus Weil <janus@gcc.gnu.org>
PR fortran/78593
* primary.c (gfc_match_varspec): Check if sym is non-null to avoid ICE.
2016-11-30 Janus Weil <janus@gcc.gnu.org>
PR fortran/78593
* gfortran.dg/derived_result.f90: New test case.
From-SVN: r243020
Diffstat (limited to 'gcc/fortran/primary.c')
-rw-r--r-- | gcc/fortran/primary.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/fortran/primary.c b/gcc/fortran/primary.c index 50d7072..2b20f8c 100644 --- a/gcc/fortran/primary.c +++ b/gcc/fortran/primary.c @@ -2050,7 +2050,7 @@ gfc_match_varspec (gfc_expr *primary, int equiv_flag, bool sub_flag, if (m != MATCH_YES) return MATCH_ERROR; - if (sym->f2k_derived) + if (sym && sym->f2k_derived) tbp = gfc_find_typebound_proc (sym, &t, name, false, &gfc_current_locus); else tbp = NULL; |