-
Notifications
You must be signed in to change notification settings - Fork 242
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
lib/: Some improvements to sizes of array parameters #1134
Open
alejandro-colomar
wants to merge
2
commits into
shadow-maint:master
Choose a base branch
from
alejandro-colomar:arrayparam
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
lib/: Some improvements to sizes of array parameters #1134
alejandro-colomar
wants to merge
2
commits into
shadow-maint:master
from
alejandro-colomar:arrayparam
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alejandro-colomar
force-pushed
the
arrayparam
branch
4 times, most recently
from
December 6, 2024 12:08
839aa80
to
fea5bcf
Compare
Queued after the release of 4.17.0. |
alejandro-colomar
force-pushed
the
arrayparam
branch
from
December 17, 2024 23:48
fea5bcf
to
40bd936
Compare
alejandro-colomar
force-pushed
the
arrayparam
branch
from
January 10, 2025 13:22
40bd936
to
91af1e4
Compare
alejandro-colomar
force-pushed
the
arrayparam
branch
from
January 18, 2025 22:31
91af1e4
to
133e9cc
Compare
'n' is just as meaningful as 'nmemb', and is in more common use in C projects (including this one). Signed-off-by: Alejandro Colomar <[email protected]>
GNU C has an extension which allows to forward-declare parameters, so that array notation can be used with sizes that are defined after the array itself. This improves the safety of such arrays, by telling the compiler the bounds of the array. This feature has been proposed for standardization in C2y as n3394. Link: n3394 <https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3394.pdf> Cc: Martin Uecker <[email protected]> Signed-off-by: Alejandro Colomar <[email protected]>
alejandro-colomar
force-pushed
the
arrayparam
branch
from
January 24, 2025 15:22
133e9cc
to
b0589f7
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The first commit is just readability stuff, but the second one is an important safety improvement.
Cc: @uecker
Revisions:
v1b
v1c
v1d
v1e
v1f
v1g
v1h
v1i