diff options
Diffstat (limited to 'gcc/fortran/primary.c')
-rw-r--r-- | gcc/fortran/primary.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/gcc/fortran/primary.c b/gcc/fortran/primary.c index c8ca3d4..09f4eb1 100644 --- a/gcc/fortran/primary.c +++ b/gcc/fortran/primary.c @@ -868,12 +868,11 @@ match_string_constant (gfc_expr **result) gfc_gobble_whitespace (); - start_locus = gfc_current_locus; - c = gfc_next_char (); if (c == '\'' || c == '"') { kind = gfc_default_character_kind; + start_locus = gfc_current_locus; goto got_delim; } @@ -917,12 +916,13 @@ match_string_constant (gfc_expr **result) goto no_match; gfc_gobble_whitespace (); - start_locus = gfc_current_locus; c = gfc_next_char (); if (c != '\'' && c != '"') goto no_match; + start_locus = gfc_current_locus; + if (kind == -1) { q = gfc_extract_int (sym->value, &kind); @@ -976,7 +976,6 @@ got_delim: e->ts.is_iso_c = 0; gfc_current_locus = start_locus; - gfc_next_char (); /* Skip delimiter */ /* We disable the warning for the following loop as the warning has already been printed in the loop above. */ |