Function: get_last_error
Applicability
Product |
Supported (√/x) |
|---|---|
√ |
|
√ |
|
√ |
|
√ |
|
√ |
Function Usage
Obtains the runtime error code of the current thread and clears the error code. If you call this API before a new error code is added to the thread, the success return code ACL_SUCCESS is returned.
Prototype
- C Prototype
1aclErroraclrtGetLastError(aclrtLastErrLevel level)
- Python Function
1ret = acl.rt.get_last_error(level)
Parameter Description
Parameter |
Description |
|---|---|
level |
Int, level of the error code to be obtained. Currently, only the thread level is supported. For details, see aclrtLastErrLevel. |
Return Value Description
Return Value |
Description |
|---|---|
ret |
Int, 0 on success; else, failure. |
Parent topic: Exception Handling