* gjs_throw_gerror_message: * * Similar to gjs_throw_gerror(), but does not marshal the GError structure into * JavaScript. Instead, it creates a regular JavaScript Error object and copies * the GError's message into it. * * Use this when handling a GError in an internal function, where the error code * and domain don't matter. So, for example, don't use it to throw errors around * calling
| 209 | * calling from JS into C code. |
| 210 | */ |
| 211 | bool gjs_throw_gerror_message(JSContext* cx, Gjs::AutoError const& error) { |
| 212 | g_return_val_if_fail(error, false); |
| 213 | gjs_throw_literal(cx, error->message); |
| 214 | return false; |
| 215 | } |
| 216 | |
| 217 | /** |
| 218 | * format_saved_frame: |
no test coverage detected