struct JSON* is opaque to scripts, so the only thing checkable at the boundary is that a pointer was passed at all — a NULL one used to fault inside nlohmann, several frames from the call that got it wrong.
| 46 | // boundary is that a pointer was passed at all — a NULL one used to fault |
| 47 | // inside nlohmann, several frames from the call that got it wrong. |
| 48 | nlohmann::json* tree(const ScriptArgs& args, int i) |
| 49 | { |
| 50 | return (nlohmann::json*)args.ptr(i); |
| 51 | } |
| 52 | |
| 53 | // The heap's destroy function for a tree: json_new's `new`, undone. |
| 54 | void deleteJson(void* ptr) |
no test coverage detected