mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 12:49:19 +00:00
LibWeb/HTML: Include better information in 'report an exception' event
Instead of always reporting a colno and lineno of zero try and use the values from the Error object that may be provided, falling back to the source location of the invocation if not provided. We can definitely improve the reporting even more, but this is a start! Also update this function to latest spec while we're in the area.
This commit is contained in:
parent
f388d3c88c
commit
57479c2d4b
Notes:
github-actions[bot]
2025-01-12 18:50:52 +00:00
Author: https://github.com/shannonbooth
Commit: 57479c2d4b
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3232
Reviewed-by: https://github.com/tcl3 ✅
6 changed files with 204 additions and 72 deletions
|
@ -72,7 +72,12 @@ public:
|
|||
GC::Ref<IndexedDB::IDBFactory> indexed_db();
|
||||
|
||||
void report_error(JS::Value e);
|
||||
void report_an_exception(JS::Value const& e);
|
||||
|
||||
enum class OmitError {
|
||||
Yes,
|
||||
No,
|
||||
};
|
||||
void report_an_exception(JS::Value exception, OmitError = OmitError::No);
|
||||
|
||||
[[nodiscard]] GC::Ref<Crypto::Crypto> crypto();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue