-
-
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
Fix SnoopCompile's snoopl
macro and add test.
#43634
Conversation
Previously the `@snoopl` functionality from SnoopCompile wasn't unit tested at all, and so it was broken in #38160, which changed the requirements for exporting C functions from the julia-internal shared lib. This commit restores the functionality by exporting it correctly, and also adds a unit test for snoopl, to make sure it isn't broken in the future. Sorry that we didn't test it in the first place! :)
We would like to eventually replace all uses of In your test, could you use |
Happily, thanks. I just copy/pasted from the test above it. Should i change that one, too, as part of this PR? |
That would be great! |
Done! :) Thanks Dilum. |
FWIW you don't necessarily have to use the That would allow you to avoid those indenting changes. |
That's true, but i actually do think the block indentation is easier to read anyway. :) Thanks tho! |
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 should have failed on CI, since there is no jl_dump_emitted_mi_name_fallback
method defined. Why did it not fail?
Yeah, agreed it should have, but it didn't fail because there weren't any tests at all that exercised the functionality until this PR. 😞 Sorry about that! In this PR, i've both fixed it, and added tests so it doesn't break again 👍 |
There were tests for it in the SnoopCompile.jl package, just not any tests here. So the failure was discovered in that package: timholy/SnoopCompile.jl#270 |
Jeff already fixed it in #43706 |
Ohhhh I misunderstood! You're saying THIS pr should have failed, cause I didn't do it right! 😅 Whoops. Thanks both Jameson and Jeff! 👍👍 |
* Fix SnoopCompile's `snoopl` macro and add test. Previously the `@snoopl` functionality from SnoopCompile wasn't unit tested at all, and so it was broken in JuliaLang#38160, which changed the requirements for exporting C functions from the julia-internal shared lib. This commit restores the functionality by exporting it correctly, and also adds a unit test for snoopl, to make sure it isn't broken in the future. Sorry that we didn't test it in the first place! :)
* Fix SnoopCompile's `snoopl` macro and add test. Previously the `@snoopl` functionality from SnoopCompile wasn't unit tested at all, and so it was broken in JuliaLang#38160, which changed the requirements for exporting C functions from the julia-internal shared lib. This commit restores the functionality by exporting it correctly, and also adds a unit test for snoopl, to make sure it isn't broken in the future. Sorry that we didn't test it in the first place! :)
Thanks for pointing this out, @timholy. Fixes timholy/SnoopCompile.jl#270.