C gateway function which displays an error message to the user (same profile as the printf function) and returns an integer value specifying an error level
void Scierror(error_level,format,value_1,..,value_n)
an integer value specifying an error level
a char* string. Specifies a character string combining literal characters with conversion specifications.
Specifies the data to be converted according to the format parameter.
If the operation is successful, this function returns the number of characters printed (not including the trailing '\0' used to end output to strings).
If an error occurred, a negative value is returned.
Scierror is a C gateway function which displays an error message to the user (same profile as the printf function) and returns an integer value specifying an error level. You must include Scierror.h to benefit from this function. This header is provided in the output_stream module (this directory should be included by default).
In this example, the C gateway function prints an error message and returns the error level 133.
#include <stack-c.h> #include <Scierror.h> int sci_myscierror(char * fname) { Scierror(133,"An error has occurred: %d\n", 1); return 0; } | ![]() | ![]() |