Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expand JS error serialization #5749

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Commits on Jul 16, 2021

  1. Expand JS error serialization

    * Generalize the framework to work on any NativeError types introduced by the JS spec, instead of listing them explicitly in a way that could require future updates.
    * Also include WebAssembly Error classes.
    * Switch semantics for serializing/deserializing "message". Previously, we would check for the presence of the property, and if it was a data property, get its value, and then ToString() it. Now, we just Get() it and then structured-serialize the result. We also unconditionally install it on the other side, regardless of whether it was present on the original. This new property-cloning procedure is more general.
    * Use these new more general property cloning procedure on "cause" (for all errors) and "errors" (for objects that present as "AggregateError" objects).
    
    Closes #5716.
    domenic committed Jul 16, 2021
    Copy the full SHA
    5da5838 View commit details
    Browse the repository at this point in the history