NAG Library Function Document
nag_code_to_error_name (x04ndc)
1
Purpose
nag_code_to_error_name (x04ndc) converts an integer error code to its corresponding string error name.
The integer error code is typically returned as part of the NAG error structure by a prior call to a NAG C Library function.
2
Specification
#include <nag.h> |
#include <nagx04.h> |
const char * |
nag_code_to_error_name (int code)
|
|
3
Description
nag_code_to_error_name (x04ndc) takes as input the value of the integer error code returned in the NAG error structure and returns the corresponding string error name. This can be useful when you want to print the returned error code as a name. For example the NE_BAD_PARAM code has the value . A call to nag_code_to_error_name (x04ndc) returns the string ‘NE_BAD_PARAM’.
nag_code_to_error_name (x04ndc) returns (null pointer) if the input value is not recognized as a valid NAG error code.
4
References
None.
5
Arguments
- 1:
– intInput
-
On entry: the value of a NAG error code.
6
Error Indicators and Warnings
None.
7
Accuracy
Not applicable.
8
Parallelism and Performance
nag_code_to_error_name (x04ndc) is not threaded in any implementation.
None.
10
Example
This example produces error name strings corresponding to a number of integer error codes.
10.1
Program Text
Program Text (x04ndce.c)
10.2
Program Data
None.
10.3
Program Results
Program Results (x04ndce.r)