-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Don't use old-style unprototyped C functions #11764
Conversation
Yes, there are more occurrences that I hadn't caught. Please give me a couple of minutes ;) |
Take your time :-) |
911ef04
to
817605a
Compare
If all is right, #11763 should show that this PR fixes all old-style prototypes on Linux, macOS and Windows since it adds warnings to catch them. |
f(void)
, not f()
Awesome, @MisterDA!
|
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.
Looks great, thanks a lot! Just to make sure, I'm running a round of CI precheck to get feedback on all Windows ports. Will merge afterwards.
Fixes strict-prototypes and old-style-definition warnings. As a reminder, `f()` declares `f` as an old-style function that can be applied to any number of arguments.
Fixes strict-prototypes and old-style-definition warnings.
817605a
to
28c4300
Compare
I've just force-pushed and applied this that I had forgotten:
|
CI precheck was happy, so I added a Changes entry and merged. |
Fixes strict-prototypes and old-style-definition warnings. As a reminder,
f()
declaresf
as an old-style function that can be applied to any number of arguments.Subsumes and closes #11762.
Note: I've just noticed that I haven't enabled the warnings on mingw, so I haven't checked the prototypes on Windows only code yet.