MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / set_error_msg

Method set_error_msg

lite/lite-c/src/global.cpp:10–13  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

8 std::string& get_error_msg() { return error_msg; }
9 ErrorCode get_error_code() { return error_code; }
10 void set_error_msg(const std::string& msg, ErrorCode code) {
11 error_msg = msg + ", Error Code: " + std::to_string(code);
12 error_code = code;
13 }
14
15 void clear_error() {
16 error_code = ErrorCode::OK;

Callers 1

LiteHandleExceptionFunction · 0.80

Calls 1

to_stringFunction · 0.85

Tested by

no test coverage detected