On Thu, 24 May 2018, Liu Hao wrote:

在 2018/5/24 1:35, Martin Storsjö 写道:
I guess that's doable (I guess you mean __SIZEOF_LONG__ * 8?), although I'd maybe rather use "sizeof(Mask) * 8" instead.

// Martin

`__*_WIDTH__` macros are documented on
<https://gcc.gnu.org/onlinedocs/cpp/Common-Predefined-Macros.html>

That seems like a very new addition, too new to rely on. Notice how it is present in the 7.1.0 docs [1] but missing in the 6.1.0 docs [2].

Additionally, clang does seem to define this kind of macros, but not all of them (it defines e.g. __SIZE_WIDTH__ but not __LONG_WIDTH__).

[1] https://gcc.gnu.org/onlinedocs/gcc-7.1.0/cpp/Common-Predefined-Macros.html
[2] https://gcc.gnu.org/onlinedocs/gcc-6.1.0/cpp/Common-Predefined-Macros.html

// Martin
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to