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

JavaScript-based Debugging API #938

Open
RyanLamansky opened this issue Jan 4, 2017 · 4 comments
Open

JavaScript-based Debugging API #938

RyanLamansky opened this issue Jan 4, 2017 · 4 comments

Comments

@RyanLamansky
Copy link

Although there are some expectations in the Tooling support document, I'd like to see formal support for JavaScript-based debugging as part of the WebAssembly object itself. With a handful of features (read-only access to the stack, break points), it becomes possible to build a self-hosting compiler and IDE within a web browser.

@lukewagner
Copy link
Member

I think this sort of API isn't something we could expose to content by default (there's no distinguishing debugger vs. debuggee; it's all just content). However, #708 proposes a design that does separate out a content-debugger which could be given a special debugging API.

@RyanLamansky
Copy link
Author

Although I wrote about this in a general sense, I'm particularly interested in iOS, which has a large user base and a severely locked down web browser. Cooperation from Apple on a debugger interface is far from assured. Having it built into the JavaScript spec allows it to work independently of Apple's vision of how their products are to be used.

@flagxor flagxor added this to the Future Features milestone Feb 3, 2017
@kevinbarabash
Copy link

Providing a debugging API that's accessible from JS allows debugging from web-based IDEs. This is particular important for web-based development environments that are targeted at novice developers.

@kevinbarabash
Copy link

there's no distinguishing debugger vs. debuggee; it's all just content

I think one way to address is to provide a for the JS code that initializes a WebAssembly module to specify a debugging "delegate" that can control things like setting break points, stepping, and whether to break on load (to debug the "start" segment if necessary).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants