Menu

#189 Using WIN32 Macro instead of _WIN32

None
closed-fixed
None
5
2017-10-11
2017-10-09
No

Hello,

This ticket is just about a little detail and its not exactly a bug.
Me and my team are cross-compiling for windows, and we noticed that you are often using the WIN32 macro in your source files to check the current compilator platform.
We needed to switch these macros to _WIN32 because in our case, we are compiling with the -std=c++14 flag and is disable WIN32 cause it's not in the standard.
To my mind, It would be a bit safer if those WIN32 were switched to _WIN32 in a further version of PlPlot!

Here is a nice topic on that point : https://stackoverflow.com/questions/662084/whats-the-difference-between-the-win32-and-win32-defines-in-c/662543#662543

Regards,
Alaric Senat

Discussion

  • Alan W. Irwin

    Alan W. Irwin - 2017-10-11
    • status: open --> closed-fixed
    • assigned_to: Alan W. Irwin
    • Group: -->
     
  • Alan W. Irwin

    Alan W. Irwin - 2017-10-11

    Thanks for your bug report which inspired us (see https://sourceforge.net/p/plplot/plplot/ci/14ecc4bd943caa40a830e0da066ff7a220b9d5e8/) to change all instances of the use of the WIN32 and __WIN32__ macros in our C and C++ source code to use _WIN32 instead. Please try this fix yourself to make sure it works for you.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.