Project

Profile

Help

HostedRedmine.com has moved to the Planio platform. All logins and passwords remained the same. All users will be able to login and use Redmine just as before. "Read more...":https://support.plan.io/news/187

Bug #856478

closed

-Wold-style-definition compiler warnings

Added by Jacob Nevins about 3 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
-
Sprint/Milestone:
Start date:
Due date:
% Done:

0%

Estimated time:

Description

Noticed this in passing:

bool techs_have_fixed_costs()

I can't think of a reason not to clean all of these up.


Files

m-fix-old-style-definition.patch (27 KB) m-fix-old-style-definition.patch master Jacob Nevins, 2020-01-18 07:32 PM
30-fix-old-style-definition.patch (26.7 KB) 30-fix-old-style-definition.patch S3_0 Jacob Nevins, 2020-01-18 07:32 PM
26-fix-old-style-definition.patch (31.3 KB) 26-fix-old-style-definition.patch S2_6 Jacob Nevins, 2020-01-18 07:32 PM

Related issues

Blocks Freeciv - Feature #856477: Enable -Wold-style-definition (in --enable-debug builds)ClosedJacob Nevins

Actions
Actions #1

Updated by Jacob Nevins about 3 years ago

  • Blocks Feature #856477: Enable -Wold-style-definition (in --enable-debug builds) added
Actions #2

Updated by Jacob Nevins about 3 years ago

Almost all of these are foo() instead of foo(void).

I agonised a little about S2_6 client/gui-xaw/pixcomm.c, which is more complex, since it looks like it has provenance from the X Window System sources. But I ended up correcting it because:
  • We haven't been shy about correcting these before (703b2169a4)
  • The relevant function looks like it might originally have been ours (0928ce1167)
  • The code it was probably forked from (ancestor of this) has long since gone to new-style definitions
  • This code dies with S2_6

(Old X version history is surprisingly hard to find!)

Actions #3

Updated by Marko Lindqvist about 3 years ago

Jacob Nevins wrote:

Almost all of these are foo() instead of foo(void).

Were function declarations for all of these already ok? I don't see you changing any of those.

Actions #4

Updated by Jacob Nevins about 3 years ago

The ones I checked were OK (I didn't check them all). I assume -Wold-style-declaration got them.

Actions #5

Updated by Jacob Nevins about 3 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF