-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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: Replace use of stage1 function pointers #12761
Conversation
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.
Relevant search entries (escaping missing): grep 'builtin.zig_backend'
, grep '.stage1'
, grep ': fn ('
, grep '*const fn ('
, grep '*fn ('
- The alignment is also missing in a few other places.
- Can you comment on where alignment is necessary and where not? I do see
align(8)
andalign(1)
in a couple of places. Might be worth double checking those for ABI problems, when there are many eyes on this change anyway.
related: #12813 |
This should be ready to merge, I'll just rebase to get the checks to run correctly. |
e8699ce
to
10c76e3
Compare
Looks like I missed a few function pointers for Windows, will fix them. |
a0b47b3
to
bf23dde
Compare
Tests passing, ready to be merged. |
Found a couple of mistakes in this PR, and also a merge conflict, will get those fixed. Please merge soon! |
bf23dde
to
f752dee
Compare
@andrewrk Can this be merged before it goes stale again? |
Many parts of
std
still use stage1-style function pointers. This PR removes all instances of this, replacing them with the use ofstd.meta.FnPtr
. Additionally, manually-writtenif
statements have been replaced withFnPtr
for clarity, conciseness, and to be guarantee detection and removal when stage1 support is removed fromstd
.I'll give this another check over before it's ready to merge.