MCPcopy Create free account
hub / github.com/GraphLite-AI/GraphLite / set_error

Function set_error

graphlite-ffi/src/lib.rs:404–410  ·  view source on GitHub ↗

Helper function to set error code if output pointer is not null

(error_out: *mut GraphLiteErrorCode, code: GraphLiteErrorCode)

Source from the content-addressed store, hash-verified

402
403// Helper function to set error code if output pointer is not null
404fn set_error(error_out: *mut GraphLiteErrorCode, code: GraphLiteErrorCode) {
405 if !error_out.is_null() {
406 unsafe {
407 *error_out = code;
408 }
409 }
410}
411
412#[cfg(test)]
413mod tests {

Callers 4

graphlite_openFunction · 0.85
graphlite_create_sessionFunction · 0.85
graphlite_queryFunction · 0.85
graphlite_close_sessionFunction · 0.85

Calls 1

is_nullMethod · 0.80

Tested by

no test coverage detected