-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
std.builtin.CompilerBackend: useless renaming #16805
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
std.builtin.CompilerBackend: useless renaming #16805
Conversation
… tags stage1 compiler was removed in e7d2834, so let's remove tag that occupies space while we are pre-1.0. Backend `other` not touched, `stage2_llvm` needed for boostrapping at the moment. Signed-off-by: Eric Joldasov <[email protected]>
…spirv64` Signed-off-by: Eric Joldasov <[email protected]>
…sparc64` Signed-off-by: Eric Joldasov <[email protected]>
…riscv64` Signed-off-by: Eric Joldasov <[email protected]>
…86_64` Signed-off-by: Eric Joldasov <[email protected]>
Signed-off-by: Eric Joldasov <[email protected]>
…aarch64` Signed-off-by: Eric Joldasov <[email protected]>
Signed-off-by: Eric Joldasov <[email protected]>
Signed-off-by: Eric Joldasov <[email protected]>
Signed-off-by: Eric Joldasov <[email protected]>
Signed-off-by: Eric Joldasov <[email protected]>
…m`, reorder integer values Signed-off-by: Eric Joldasov <[email protected]>
Signed-off-by: Eric Joldasov <[email protected]>
I think you're misunderstanding the purpose of this enum. The whole point of it is to work around issues in compiler implementations, using compiler-specific logic. Because the stage1 compiler existed at one point in time, the enum tag exists to allow programs - both old and new - to support it if they desire. IMO, this enum should never have tags removed: it is intended to be a record of every major Zig compiler implementation which has existed, and removing tags is a completely pointless breaking change with no benefits and some potential (if minor) downsides. Additionally, renaming |
Ok, nearly got it, but should it then be commented as such ( |
Remove
stage1
tag since old C++ compiler wasremovedNUKED in #13560, rename remainingstage2_*
backends tozsf_*
(choosed this prefix for clarity over simply omitting old prefix, but if you want I can omit it or change to other prefix).Gains one more free tag (out of 18_446_744_073_709_551_615)
and one possible bug removed (switching/checking(I forgot that this enum is non-exhaustive)if (backend == .stage1)
even when this compiler was removed)