This commit is contained in:
Chris Boesch 2024-11-25 22:59:49 -07:00 committed by GitHub
commit 6f4798b2b8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -3311,7 +3311,7 @@ void do_a_thing(struct Foo *foo) {
</p>
<p>
One benefit to this is that functions which take pointers as arguments can
be annotated with the "nonnull" attribute - <code>__attribute__((nonnull))</code> in
be annotated with the "nonnull" attribute, which corresponds to the <code>__attribute__((nonnull))</code> in
<a href="https://gcc.gnu.org/onlinedocs/gcc-4.0.0/gcc/Function-Attributes.html">GCC</a>.
The optimizer can sometimes make better decisions knowing that pointer arguments
cannot be null.