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

Use proper mapexpr include feature for rewriting included expressions #48

Merged
merged 1 commit into from
Oct 17, 2024

Conversation

Keno
Copy link
Contributor

@Keno Keno commented Oct 17, 2024

As of Julia 1.5, include has an official feature to rewrite the parsed expressions - no need manually mess with textual includes and parsing. Using this feature rather than relying on Base internals is recommended as it makes the package more robust to future changes in this infrastructure. In particular, I'm planning to change the module-local include to allow extensions in JuliaLang/julia#55949. This package is currently doing that, though it could be changed not to. However, by just using the official feature for what this package wants to do, we just sidestep the question entirely. The old code is retained for pre-1.5 compat.

As of Julia 1.5, `include` has an official feature to rewrite the parsed
expressions - no need manually mess with textual includes and parsing.
Using this feature rather than relying on Base internals is recommended
as it makes the package more robust to future changes in this infrastructure.
In particular, I'm planning to change the module-local `include` to
allow extensions in JuliaLang/julia#55949.
This package is currently doing that, though it could be changed not
to. However, by just using the official feature for what this package
wants to do, we just sidestep the question entirely. The old code is
retained for pre-1.5 compat.
@JeffreySarnoff
Copy link
Owner

Thank you!

@JeffreySarnoff JeffreySarnoff merged commit 79e64b1 into JeffreySarnoff:main Oct 17, 2024
12 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants