Skip to content

Conversation

@xal-0
Copy link
Member

@xal-0 xal-0 commented Oct 8, 2025

Previously, map-cl-convert would keep the toplevel flag only when the containing expression was toplevel and each element of the list passed to it satisfied toplevel-preserving?. Instead, make it so toplevel-preserving? expressions are those where the toplevel flag should be propagated to the children during closure conversion.

Fixes #59755.

@xal-0 xal-0 added compiler:lowering Syntax lowering (compiler front end, 2nd stage) bugfix This change fixes an existing bug labels Oct 8, 2025
@xal-0 xal-0 force-pushed the toplevel-global-lowering branch from e890d9a to 52ed9a2 Compare October 8, 2025 17:26
Previously, `map-cl-convert` would keep the toplevel flag only when the
containing expression was toplevel and each element of the list passed to it
satisfied `toplevel-preserving?`.  Instead, make it so `toplevel-preserving?`
expressions are those where the toplevel flag should be propagated to the
children during closure conversion.

Fixes JuliaLang#59755.
@xal-0 xal-0 force-pushed the toplevel-global-lowering branch from 52ed9a2 to 9174682 Compare October 14, 2025 17:59
@xal-0 xal-0 merged commit 1cbea07 into JuliaLang:master Oct 17, 2025
5 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix This change fixes an existing bug compiler:lowering Syntax lowering (compiler front end, 2nd stage)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Core.declare_global is hoisted out of if/else at the top level

2 participants