diff options
Diffstat (limited to 'gcc/fortran')
-rw-r--r-- | gcc/fortran/ChangeLog | 19 | ||||
-rw-r--r-- | gcc/fortran/decl.c | 10 | ||||
-rw-r--r-- | gcc/fortran/f95-lang.c | 2 | ||||
-rw-r--r-- | gcc/fortran/interface.c | 2 | ||||
-rw-r--r-- | gcc/fortran/intrinsic.c | 8 | ||||
-rw-r--r-- | gcc/fortran/module.c | 14 | ||||
-rw-r--r-- | gcc/fortran/primary.c | 2 | ||||
-rw-r--r-- | gcc/fortran/resolve.c | 18 | ||||
-rw-r--r-- | gcc/fortran/scanner.c | 2 | ||||
-rw-r--r-- | gcc/fortran/trans-expr.c | 4 |
10 files changed, 50 insertions, 31 deletions
diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 9cefe39..4982574 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,22 @@ +2019-03-12 Martin Liska <mliska@suse.cz> + + * decl.c (add_init_expr_to_sym): Replace usage of 'can't' + with 'cannot'. + (variable_decl): Likewise. + (cray_pointer_decl): Likewise. + (match_binding_attributes): Likewise. + * f95-lang.c (gfc_init): Likewise. + * interface.c (gfc_check_typebound_override): Likewise. + * intrinsic.c (make_generic): Likewise. + * module.c (dump_module): Likewise. + (gfc_use_module): Likewise. + * primary.c (gfc_convert_to_structure_constructor): Likewise. + * resolve.c (resolve_entries): Likewise. + (check_generic_tbp_ambiguity): Likewise. + (get_checked_tb_operator_target): Likewise. + * scanner.c (load_file): Likewise. + * trans-expr.c (gfc_conv_intrinsic_to_class): Likewise. + 2019-03-12 Paul Thomas <pault@gcc.gnu.org> PR fortran/89363 diff --git a/gcc/fortran/decl.c b/gcc/fortran/decl.c index a29e2db..f6411f1 100644 --- a/gcc/fortran/decl.c +++ b/gcc/fortran/decl.c @@ -1978,7 +1978,7 @@ add_init_expr_to_sym (const char *name, gfc_expr **initp, locus *var_locus) if (init->rank == 0) { - gfc_error ("Can't initialize implied-shape array at %L" + gfc_error ("Cannot initialize implied-shape array at %L" " with scalar", &sym->declared_at); return false; } @@ -2490,7 +2490,7 @@ variable_decl (int elem) if (as->type == AS_IMPLIED_SHAPE && current_attr.flavor != FL_PARAMETER) { m = MATCH_ERROR; - gfc_error ("Non-PARAMETER symbol %qs at %L can't be implied-shape", + gfc_error ("Non-PARAMETER symbol %qs at %L cannot be implied-shape", name, &var_locus); goto cleanup; } @@ -2668,7 +2668,7 @@ variable_decl (int elem) else { if (!gfc_set_array_spec (sym, cp_as, &var_locus)) - gfc_internal_error ("Couldn't set pointee array spec."); + gfc_internal_error ("Cannot set pointee array spec."); /* Fix the array spec. */ m = gfc_mod_pointee_as (sym->as); @@ -8538,7 +8538,7 @@ cray_pointer_decl (void) if (cpte->as == NULL) { if (!gfc_set_array_spec (cpte, as, &var_locus)) - gfc_internal_error ("Couldn't set Cray pointee array spec."); + gfc_internal_error ("Cannot set Cray pointee array spec."); } else if (as != NULL) { @@ -10706,7 +10706,7 @@ match_binding_attributes (gfc_typebound_proc* ba, bool generic, bool ppc) /* NON_OVERRIDABLE and DEFERRED exclude themselves. */ if (ba->non_overridable && ba->deferred) { - gfc_error ("NON_OVERRIDABLE and DEFERRED can't both appear at %C"); + gfc_error ("NON_OVERRIDABLE and DEFERRED cannot both appear at %C"); goto error; } diff --git a/gcc/fortran/f95-lang.c b/gcc/fortran/f95-lang.c index ad81f7d..3e3d304 100644 --- a/gcc/fortran/f95-lang.c +++ b/gcc/fortran/f95-lang.c @@ -248,7 +248,7 @@ gfc_init (void) gfc_init_1 (); if (!gfc_new_file ()) - fatal_error (input_location, "can't open input file: %s", gfc_source_file); + fatal_error (input_location, "cannot open input file: %s", gfc_source_file); if (flag_preprocess_only) return false; diff --git a/gcc/fortran/interface.c b/gcc/fortran/interface.c index a07e658d..c9781d7 100644 --- a/gcc/fortran/interface.c +++ b/gcc/fortran/interface.c @@ -4552,7 +4552,7 @@ gfc_check_typebound_override (gfc_symtree* proc, gfc_symtree* old) /* If the overwritten procedure is GENERIC, this is an error. */ if (old->n.tb->is_generic) { - gfc_error ("Can't overwrite GENERIC %qs at %L", + gfc_error ("Cannot overwrite GENERIC %qs at %L", old->name, &proc->n.tb->where); return false; } diff --git a/gcc/fortran/intrinsic.c b/gcc/fortran/intrinsic.c index 4797b3d..c21fbdd 100644 --- a/gcc/fortran/intrinsic.c +++ b/gcc/fortran/intrinsic.c @@ -1157,7 +1157,7 @@ make_generic (const char *name, gfc_isym_id id, int standard ATTRIBUTE_UNUSED) g = gfc_find_function (name); if (g == NULL) - gfc_internal_error ("make_generic(): Can't find generic symbol %qs", + gfc_internal_error ("make_generic(): Cannot find generic symbol %qs", name); gcc_assert (g->id == id); @@ -4217,7 +4217,7 @@ keywords: gfc_error ("The argument list functions %%VAL, %%LOC or %%REF " "are not allowed in this context at %L", where); else - gfc_error ("Can't find keyword named %qs in call to %qs at %L", + gfc_error ("Cannot find keyword named %qs in call to %qs at %L", a->name, name, where); return false; } @@ -5179,12 +5179,12 @@ gfc_convert_type_warn (gfc_expr *expr, gfc_typespec *ts, int eflag, int wflag) bad: if (eflag == 1) { - gfc_error ("Can't convert %s to %s at %L", + gfc_error ("Cannot convert %s to %s at %L", gfc_typename (&from_ts), gfc_typename (ts), &expr->where); return false; } - gfc_internal_error ("Can't convert %qs to %qs at %L", + gfc_internal_error ("Cannot convert %qs to %qs at %L", gfc_typename (&from_ts), gfc_typename (ts), &expr->where); /* Not reached */ diff --git a/gcc/fortran/module.c b/gcc/fortran/module.c index 320b30c..0572b8e 100644 --- a/gcc/fortran/module.c +++ b/gcc/fortran/module.c @@ -6170,7 +6170,7 @@ dump_module (const char *name, int dump_flag) /* Write the module to the temporary file. */ module_fp = gzopen (filename_tmp, "w"); if (module_fp == NULL) - gfc_fatal_error ("Can't open module file %qs for writing at %C: %s", + gfc_fatal_error ("Cannot open module file %qs for writing at %C: %s", filename_tmp, xstrerror (errno)); /* Use lbasename to ensure module files are reproducible regardless @@ -6202,16 +6202,16 @@ dump_module (const char *name, int dump_flag) { /* Module file have changed, replace the old one. */ if (remove (filename) && errno != ENOENT) - gfc_fatal_error ("Can't delete module file %qs: %s", filename, + gfc_fatal_error ("Cannot delete module file %qs: %s", filename, xstrerror (errno)); if (rename (filename_tmp, filename)) - gfc_fatal_error ("Can't rename module file %qs to %qs: %s", + gfc_fatal_error ("Cannot rename module file %qs to %qs: %s", filename_tmp, filename, xstrerror (errno)); } else { if (remove (filename_tmp)) - gfc_fatal_error ("Can't delete temporary module file %qs: %s", + gfc_fatal_error ("Cannot delete temporary module file %qs: %s", filename_tmp, xstrerror (errno)); } } @@ -7000,7 +7000,7 @@ gfc_use_module (gfc_use_list *module) module_fp = gzopen_intrinsic_module (filename); if (module_fp == NULL && module->intrinsic) - gfc_fatal_error ("Can't find an intrinsic module named %qs at %C", + gfc_fatal_error ("Cannot find an intrinsic module named %qs at %C", module_name); /* Check for the IEEE modules, so we can mark their symbols @@ -7028,7 +7028,7 @@ gfc_use_module (gfc_use_list *module) { if (gfc_state_stack->state != COMP_SUBMODULE && module->submodule_name == NULL) - gfc_fatal_error ("Can't open module file %qs for reading at %C: %s", + gfc_fatal_error ("Cannot open module file %qs for reading at %C: %s", filename, xstrerror (errno)); else gfc_fatal_error ("Module file %qs has not been generated, either " @@ -7088,7 +7088,7 @@ gfc_use_module (gfc_use_list *module) for (p = gfc_state_stack; p; p = p->previous) if ((p->state == COMP_MODULE || p->state == COMP_SUBMODULE) && strcmp (p->sym->name, module_name) == 0) - gfc_fatal_error ("Can't USE the same %smodule we're building", + gfc_fatal_error ("Cannot USE the same %smodule we're building", p->state == COMP_SUBMODULE ? "sub" : ""); init_pi_tree (); diff --git a/gcc/fortran/primary.c b/gcc/fortran/primary.c index 5bfb90c..e918372 100644 --- a/gcc/fortran/primary.c +++ b/gcc/fortran/primary.c @@ -2979,7 +2979,7 @@ gfc_convert_to_structure_constructor (gfc_expr *e, gfc_symbol *sym, gfc_expr **c if (!parent && sym->attr.abstract) { - gfc_error ("Can't construct ABSTRACT type %qs at %L", + gfc_error ("Cannot construct ABSTRACT type %qs at %L", sym->name, &expr->where); goto cleanup; } diff --git a/gcc/fortran/resolve.c b/gcc/fortran/resolve.c index 1cf9cba..6677deb 100644 --- a/gcc/fortran/resolve.c +++ b/gcc/fortran/resolve.c @@ -838,22 +838,22 @@ resolve_entries (gfc_namespace *ns) if (sym->attr.dimension) { if (el == ns->entries) - gfc_error ("FUNCTION result %s can't be an array in " + gfc_error ("FUNCTION result %s cannot be an array in " "FUNCTION %s at %L", sym->name, ns->entries->sym->name, &sym->declared_at); else - gfc_error ("ENTRY result %s can't be an array in " + gfc_error ("ENTRY result %s cannot be an array in " "FUNCTION %s at %L", sym->name, ns->entries->sym->name, &sym->declared_at); } else if (sym->attr.pointer) { if (el == ns->entries) - gfc_error ("FUNCTION result %s can't be a POINTER in " + gfc_error ("FUNCTION result %s cannot be a POINTER in " "FUNCTION %s at %L", sym->name, ns->entries->sym->name, &sym->declared_at); else - gfc_error ("ENTRY result %s can't be a POINTER in " + gfc_error ("ENTRY result %s cannot be a POINTER in " "FUNCTION %s at %L", sym->name, ns->entries->sym->name, &sym->declared_at); } @@ -891,12 +891,12 @@ resolve_entries (gfc_namespace *ns) if (sym) { if (el == ns->entries) - gfc_error ("FUNCTION result %s can't be of type %s " + gfc_error ("FUNCTION result %s cannot be of type %s " "in FUNCTION %s at %L", sym->name, gfc_typename (ts), ns->entries->sym->name, &sym->declared_at); else - gfc_error ("ENTRY result %s can't be of type %s " + gfc_error ("ENTRY result %s cannot be of type %s " "in FUNCTION %s at %L", sym->name, gfc_typename (ts), ns->entries->sym->name, &sym->declared_at); @@ -13115,7 +13115,7 @@ check_generic_tbp_ambiguity (gfc_tbp_generic* t1, gfc_tbp_generic* t2, if (sym1->attr.subroutine != sym2->attr.subroutine || sym1->attr.function != sym2->attr.function) { - gfc_error ("%qs and %qs can't be mixed FUNCTION/SUBROUTINE for" + gfc_error ("%qs and %qs cannot be mixed FUNCTION/SUBROUTINE for" " GENERIC %qs at %L", sym1->name, sym2->name, generic_name, &where); return false; @@ -13250,7 +13250,7 @@ specific_found: /* If we attempt to "overwrite" a specific binding, this is an error. */ if (p->overridden && !p->overridden->is_generic) { - gfc_error ("GENERIC %qs at %L can't overwrite specific binding with" + gfc_error ("GENERIC %qs at %L cannot overwrite specific binding with" " the same name", name, &p->where); return false; } @@ -13306,7 +13306,7 @@ get_checked_tb_operator_target (gfc_tbp_generic* target, locus where) /* F08:C468. All operator bindings must have a passed-object dummy argument. */ if (target->specific->nopass) { - gfc_error ("Type-bound operator at %L can't be NOPASS", &where); + gfc_error ("Type-bound operator at %L cannot be NOPASS", &where); return NULL; } diff --git a/gcc/fortran/scanner.c b/gcc/fortran/scanner.c index 08e4521..eeba2ab 100644 --- a/gcc/fortran/scanner.c +++ b/gcc/fortran/scanner.c @@ -2469,7 +2469,7 @@ load_file (const char *realfilename, const char *displayedname, bool initial) if (input == NULL) { - gfc_error_now ("Can't open file %qs", filename); + gfc_error_now ("Cannot open file %qs", filename); return false; } } diff --git a/gcc/fortran/trans-expr.c b/gcc/fortran/trans-expr.c index 1a48e73..9019c55 100644 --- a/gcc/fortran/trans-expr.c +++ b/gcc/fortran/trans-expr.c @@ -926,8 +926,8 @@ gfc_conv_intrinsic_to_class (gfc_se *parmse, gfc_expr *e, } else { - gfc_error ("Can't compute the length of the char array at %L.", - &e->where); + gfc_error ("Cannot compute the length of the char array " + "at %L.", &e->where); } } } |