vmlSetErrorCallBack
vmlSetErrorCallBack
Sets the additional error handler callback function and gets the old callback function.
Syntax
oldcallback
=
vmlSetErrorCallBack
(
callback
)
;
Include Files
- mkl.h
Input Parameters
Name | Description | |
---|---|---|
callback | Pointer to the callback function. | The callback function has the following format:
stdcall functionality has been deprecated and will be removed in a future release of the product. The passed error structure is defined as follows:
|
Output Parameters
Name | Type | Description |
---|---|---|
oldcallback | int | Pointer to the former callback function. |
Description
The callback function is called on each VM mathematical function error if
VML_ERRMODE_CALLBACK
error mode is set .Use the
vmlSetErrorCallBack()
function if you need to define your own callback function instead of default empty callback function.The input structure for a callback function contains the following information about the error encountered:
- the input value that caused an error
- location (array index) of this value
- the computed result value
- error code
- name of the function in which the error occurred.
You can insert your own error processing into the callback function. This may include correcting the passed result values in order to pass them back and resume computation. The standard error handler is called after the callback function only if it returns
0
.