summaryrefslogtreecommitdiff
path: root/libgfortran/runtime
diff options
context:
space:
mode:
authorjvdelisle <jvdelisle@138bc75d-0d04-0410-961f-82ee72b054a4>2007-05-06 22:28:31 +0000
committerjvdelisle <jvdelisle@138bc75d-0d04-0410-961f-82ee72b054a4>2007-05-06 22:28:31 +0000
commit13f02ebc93cfbda419d1008b88b16b791ed9a5ee (patch)
treeda33f84dfec782004c14205e386d8a57f79aecc9 /libgfortran/runtime
parentc15062b7ed8684a647d5dede3ef243056cb46158 (diff)
downloadgcc-13f02ebc93cfbda419d1008b88b16b791ed9a5ee.tar.gz
2007-05-06 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR libfortran/31201 * runtime/error.c (runtime_error_at): New function. (generate_error): Export this function. * gfortran.map: Add _gfortran_generate_error and _gfortran_runtime_error_at. * libgfortran.h: Add comment to reference error codes in front end. (library_start): Locate prototype with library_end macro and add a new comment. Add prototype for runtime_error_at. Export prototype for generate_error. * io/lock.c (library_start): Fix check for error condition. * io/transfer.c (data_transfer_init): Add library check. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@124479 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libgfortran/runtime')
-rw-r--r--libgfortran/runtime/error.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/libgfortran/runtime/error.c b/libgfortran/runtime/error.c
index 3c44d218963..2bcc293091a 100644
--- a/libgfortran/runtime/error.c
+++ b/libgfortran/runtime/error.c
@@ -299,6 +299,19 @@ runtime_error (const char *message)
}
iexport(runtime_error);
+/* void runtime_error_at()-- These are errors associated with a
+ * run time error generated by the front end compiler. */
+
+void
+runtime_error_at (const char *where, const char *message)
+{
+ recursion_check ();
+ st_printf ("%s\n", where);
+ st_printf ("Fortran runtime error: %s\n", message);
+ sys_exit (2);
+}
+iexport(runtime_error_at);
+
/* void internal_error()-- These are this-can't-happen errors
* that indicate something deeply wrong. */
@@ -475,7 +488,7 @@ generate_error (st_parameter_common *cmp, int family, const char *message)
st_printf ("Fortran runtime error: %s\n", message);
sys_exit (2);
}
-
+iexport(generate_error);
/* Whether, for a feature included in a given standard set (GFC_STD_*),
we should issue an error or a warning, or be quiet. */