Skip to content
New issue

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

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

Already on GitHub? # to your account

Implement Error.prepareStackTrace support #223

Merged
merged 1 commit into from
Dec 19, 2023
Merged

Conversation

saghul
Copy link
Contributor

@saghul saghul commented Dec 17, 2023

Based on V8's API: https://v8.dev/docs/stack-trace-api.

Bits picked from Frida: frida/quickjs@78fd25f

Closes: #134

@saghul
Copy link
Contributor Author

saghul commented Dec 17, 2023

@bnoordhuis Can you PTAL? It's not fully finished yet (see TODOs) but I'd like some feedback on the approach.

The tricky part was to avoid doing anything while iterating through the stack frames since they could get modified while we are iterating over them.

Edit: also, do you reckon there is more low hanging fruit I could add, to make the API closer to V8's?

@saghul saghul force-pushed the error-prepareStackTrace branch from da9c7b2 to 66c95b4 Compare December 19, 2023 08:39
@saghul saghul marked this pull request as ready for review December 19, 2023 08:39
@saghul
Copy link
Contributor Author

saghul commented Dec 19, 2023

Alright, this is one is ready now, PTAL @bnoordhuis !

@saghul saghul force-pushed the error-prepareStackTrace branch from 66c95b4 to 07fad07 Compare December 19, 2023 14:22
@saghul saghul merged commit 555d837 into master Dec 19, 2023
@saghul saghul deleted the error-prepareStackTrace branch December 19, 2023 14:36
@saghul
Copy link
Contributor Author

saghul commented Dec 19, 2023

🔥

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Error.prepareStackTrace support
3 participants