Opened 12 years ago Closed 12 years ago #666 closed defect (fixed)Compiler error in 32-bit build
Description
Compiler error on a 32-bit build (present since HM-7.2):
Root cause:
Offending code:
Corrected code:
Change: Change History (5)comment:1 Changed 12 years ago by DefaultCC Plugin
comment:2 Changed 12 years ago by ksuehringcomment:3 Changed 12 years ago by ksuehring
comment:4 Changed 12 years ago by ksuehring
comment:5 Changed 12 years ago by ksuehring
Fixed following the original suggestion in the ticket in r2747. We should actually remove all own MAX* defines and use the ones from the system, but at the moment just make it compile again. Note: See
TracTickets for help on using
tickets. | This list contains all users that will be notified about changes made to this ticket. These roles will be notified: Reporter, Owner, Subscriber, Participant
|
I was wondering why we are not using the C standard limits INT_MAX, UINT_MAX, etc.
But it seems on Linux INT64_MAX is only defined for C, not C++ (at least in stdint.h) and on Windows we have _INT64_MAX.
The C++ way of doing this would probably be the following:
Shall we correct it that way?