-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Report the top of the exception stack when there's no handler. #38679
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks useful, I'm only confused that it's necessary — we seem to only call jl_no_exc_handler
with either the current exception in task.c, or using jl_current_exception()
. Or does PackageCompiler call jl_no_exc_handler
?
After this change, it'll be unnecessary to pass jl_current_exception
here (as this will be the default) so perhaps you could change those other couple of call sites too.
753989d
to
ec26f45
Compare
During |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh I see. Yes it appears the use of NULL to signify "this is a rethrow" has led to confusion here.
Well this code LGTM (other than the comment about NULL denoting the top of the stack. That's either wrong, or I'm confused by it :-) )
ec26f45
to
aaab77e
Compare
Thanks! I updated the comment to reflect NULL exceptions are only used for rethrowing. |
Looks great 👍 |
…_handler Report the top of the exception stack when there's no handler. ------- Backport JuliaLang#38679 into release-1.5
This happens with PackageCompiler and modules that error during
__init__
(which gets called way earlier if said modules are part of the system image). Before:After:
At least the exception is there now.
cc @KristofferC