From 87bdc5f8fd0b48e0548d49d87fb7744afeadb439 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tobias=20Schl=C3=BCter?= Date: Sun, 11 Jul 2004 15:04:32 +0200 Subject: [PATCH] re PR fortran/16455 (print the location of a missing module fatal error) PR fortran/15455 * module.c (gfc_dump_module, gfc_use_module): Print locus when opening of module file fails. From-SVN: r84508 --- gcc/fortran/ChangeLog | 6 ++++++ gcc/fortran/module.c | 4 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index f8d176c2e71..cf1bf3b4bde 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,9 @@ +2004-07-11 Tobias Schlueter + + PR fortran/15455 + * module.c (gfc_dump_module, gfc_use_module): Print locus + when opening of module file fails. + 2004-07-11 Joseph S. Myers * f95-lang.c (set_block): Remove. diff --git a/gcc/fortran/module.c b/gcc/fortran/module.c index 33f050b91dc..17254ce0f54 100644 --- a/gcc/fortran/module.c +++ b/gcc/fortran/module.c @@ -3415,7 +3415,7 @@ gfc_dump_module (const char *name, int dump_flag) module_fp = fopen (filename, "w"); if (module_fp == NULL) - gfc_fatal_error ("Can't open module file '%s' for writing: %s", + gfc_fatal_error ("Can't open module file '%s' for writing at %C: %s", filename, strerror (errno)); now = time (NULL); @@ -3459,7 +3459,7 @@ gfc_use_module (void) module_fp = gfc_open_included_file (filename); if (module_fp == NULL) - gfc_fatal_error ("Can't open module file '%s' for reading: %s", + gfc_fatal_error ("Can't open module file '%s' for reading at %C: %s", filename, strerror (errno)); iomode = IO_INPUT; -- 2.30.2