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

Expose __EXCEPTION virtual variable for current EG(exception) #922

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

Conversation

zobo
Copy link
Contributor

@zobo zobo commented Nov 16, 2023

This could be a way to expose the current Exception that is in EG(exception). I have tested this with VSC and it does indeed work.

image

However, I think a better way would be to provide a dynamic context name when an exception is available.. Same with return value. Maybe....

I have not written any tests for this yet.

@derickr
Copy link
Contributor

derickr commented Nov 24, 2023

I think I'm generally OK with this, but it confuses me that tests on Windows are not failing, whereas there is a test (I think rightfully) failing on Linux. And of course, we need tests :-)

Copy link
Contributor

@derickr derickr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this should be guarded by a feature set, as we discussed in our meeting. The reason is that otherwise IDEs could suddenly see this extra virtual variable, without knowing why.

The PR should also add tests to check whether this new feature works. I don't think we should not fix the currently failing test, as it has not opted in into this new behaviour.

src/debugger/handler_dbgp.c Outdated Show resolved Hide resolved
src/lib/var.c Show resolved Hide resolved
src/debugger/handler_dbgp.c Show resolved Hide resolved
@zobo zobo force-pushed the dbgp_exception branch 3 times, most recently from 4b2e337 to d59bf03 Compare March 26, 2024 03:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants