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

langref: clarification about optionals optimization #13922

Closed
perillo opened this issue Dec 13, 2022 · 0 comments
Closed

langref: clarification about optionals optimization #13922

perillo opened this issue Dec 13, 2022 · 0 comments
Labels

Comments

@perillo
Copy link
Contributor

perillo commented Dec 13, 2022

In the https://ziglang.org/documentation/master/#Optionals, the documentation says:

"One benefit to this is that functions which take pointers as arguments can be annotated with the "nonnull" attribute - attribute((nonnull)) in GCC. The optimizer can sometimes make better decisions knowing that pointer arguments cannot be null."

This text does not seems very useful. Moreover the text seems to imply that the Zig compiler generates C code compiled with GCC (note that the text was committed in 2017-11-07).

@Vexu Vexu added the docs label Jan 1, 2023
@Vexu Vexu added this to the 0.11.0 milestone Jan 1, 2023
@andrewrk andrewrk modified the milestones: 0.11.0, 0.12.0 Jun 19, 2023
@andrewrk andrewrk closed this as not planned Won't fix, can't repro, duplicate, stale Nov 29, 2024
@andrewrk andrewrk removed this from the 0.14.0 milestone Nov 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants