Declares access to the calling thread's last C ABI diagnostic. More...
Functions | |
| const char * | apo_last_error (void) |
| Returns the current thread's most recent C ABI diagnostic. | |
Declares access to the calling thread's last C ABI diagnostic.
| const char * apo_last_error | ( | void | ) |
Returns the current thread's most recent C ABI diagnostic.
Call this function immediately after a status-returning apoCHARMM C function returns a value other than APO_STATUS_OK. The function does not clear or otherwise modify the diagnostic. A non-NULL pointer to an empty string means that no diagnostic is currently recorded.
The returned pointer is borrowed from apoCHARMM and refers to a null-terminated byte string. A later status-returning apoCHARMM C API call on the same thread clears or replaces the storage, even when that later call succeeds. Successful destruction preserves an existing diagnostic, while a destruction failure may replace it.