-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Description
Proposal
Global assembly basically requires implementing an actual assembler for its typical use cases, with all the legacy cruft that that implies: Many directives that do the same thing, directives that work in highly unintuitive ways (e.g. .symver
), a macro system (.macro
), silently overwriting symbol properties, etc.
A full assembler also has undesirable effects on the compilation pipeline because of the ability to introduce and change symbols arbitrarily, as well as the ability to switch between arbitrary sections while assembling.
We plan to implement an assembler anyway (#21169), but it's intended to be a separate tool for compiling existing assembly source files rather than one that you can invoke in the language through global assembly. For inline assembly, the plan is to have a more 'Zig-native' syntax (#10761).
Putting all of those factors together, global assembly doesn't seem worth keeping in the language.
Any use cases that are currently served by global assembly should then be served by proper language features instead, such as in #24076. If you're currently relying on global assembly, please comment with details on your use case.
cc #24046