FunctionConstruct and print an error message
Syntax C/C++#include <VecLib.h>
void V_noteError( char *fname, unsigned why );
Pascal/Delphiuses VecLib;
procedure V_noteError( fname:PChar; why:UInt );
DescriptionIn case of an error, the math functions of VectorLib invoke the following steps:
C/C++: First call _matherr (or _matherrl), then inspect the return value of _matherr (or _matherrl) and call V_noteError in case this return value was 0.

Pascal/Delphi: Call V_noteError if V_FPErrorHandlingMode contains fpErrorNote for the type of error that occurred. V_noteError then constructs the appropriate error message and passes it to V_printErrorMsg, which is the function in charge of actually printing the error message.

By default, output is directed to the screen. This may be changed by a call to V_setErrorEventFile (see chapter 5.3).

"fname" is the name of the "complaining" function, and "why" specifies the reason for the complaint.
C/C++: see the description of _matherr in your compiler's documentation for error codes.
How to call V_noteError from a user-defined _matherr function is described in chapter 5.3..

Pascal/Delphi: The parameter "why" may take on the following values:
1 for DOMAIN errors
2 for SING errors
3 for OVERFLOW errors
4 for UNDERFLOW errors
5 for TLOSS errors

This function will not be included in versions of OptiVec for compilers that do already offer the possibility of printing error messages simultaneously to the screen and to an event file.

Return valuenone
See alsoV_setErrorEventFile,   V_printErrorMsg

VectorLib Table of Contents  OptiVec home