Meta: Support DOMExceptions when invoking IDL getters/setters

This commit is contained in:
Ali Mohammad Pur 2022-02-15 13:14:54 +03:30 committed by Ali Mohammad Pur
parent ce6adf25e5
commit 57997ed336
Notes: sideshowbarker 2024-07-17 18:42:26 +09:00

View File

@ -4080,7 +4080,7 @@ JS_DEFINE_NATIVE_FUNCTION(@prototype_class@::@attribute.getter_callback@)
}
} else {
attribute_generator.append(R"~~~(
auto retval = impl->@attribute.cpp_getter_name@();
auto retval = TRY(throw_dom_exception_if_needed(global_object, [&] { return impl->@attribute.cpp_getter_name@(); }));
)~~~");
}