looks like I lose any way I try with __int128 and a 32-bit compiler. sure wish
we had a real 128-bit type. I have tried different constant suffixes to no
avail.
__int128 i=170141183460469231731687303715884105727LLL; //39 digits
unsigned __int128 u=340282366920938463463374607431768211455ULLL; //39 digits
__int128.cpp:4:16: error: invalid suffix "LLL" on integer constant
__int128.cpp:5:25: error: invalid suffix "ULLL" on integer constant
__int128.cpp: In function 'int main()':
__int128.cpp:4:5: error: expected primary-expression before '__int128'
__int128.cpp:4:5: error: expected ';' before '__int128'
__int128.cpp:5:14: error: expected unqualified-id before '__int128'
__int128 i=170141183460469231731687303715884105727LL;
unsigned __int128 u=340282366920938463463374607431768211455ULL;
__int128.cpp:4:16: warning: integer constant is too large for its type [enabled
by default]
__int128.cpp:5:25: warning: integer constant is too large for its type [enabled
by default]
__int128.cpp: In function 'int main()':
__int128.cpp:4:5: error: expected primary-expression before '__int128'
__int128.cpp:4:5: error: expected ';' before '__int128'
__int128.cpp:5:14: error: expected unqualified-id before '__int128'
__int128 i=170141183460469231731687303715884105727i128;
unsigned __int128 u=340282366920938463463374607431768211455Ui128;
__int128.cpp:4:16: error: invalid suffix "i128" on integer constant
__int128.cpp:5:25: error: invalid suffix "Ui128" on integer constant
__int128.cpp:4:5: error: expected primary-expression before '__int128'
__int128.cpp:4:5: error: expected ';' before '__int128'
__int128.cpp:5:14: error: expected unqualified-id before '__int128'
also, with printf, I get these error messages:
printf("%*d", 128/8, i);
printf("%*u", 128/8, u);
__int128.cpp:7:24: warning: field width specifier '*' expects argument of type
'int', but argument 2 has type '__int128' [-Wformat]
__int128.cpp:11:24: warning: field width specifier '*' expects argument of type
'int', but argument 2 has type '__int128 unsigned' [-Wformat]
-------------
Jim Michaels
[email protected]
[email protected]
http://JimsComputerRepairandWebDesign.com
http://JesusnJim.com (my personal site, has software)
---
Computer memory/disk size measurements:
[KB KiB] [MB MiB] [GB GiB] [TB TiB]
[10^3B=1,000B=1KB][2^10B=1,024B=1KiB]
[10^6B=1,000,000B=1MB][2^20B=1,048,576B=1MiB]
[10^9B=1,000,000,000B=1GB][2^30B=1,073,741,824B=1GiB]
[10^12B=1,000,000,000,000B=1TB][2^40B=1,099,511,627,776B=1TiB]
Note: disk size is measured in MB, GB, or TB, not in MiB, GiB, or TiB.
computer memory (RAM) is measured in MiB and GiB.------------------------------------------------------------------------------
The demand for IT networking professionals continues to grow, and the
demand for specialized networking skills is growing even more rapidly.
Take a complimentary Learning@Cisco Self-Assessment and learn
about Cisco certifications, training, and career opportunities.
http://p.sf.net/sfu/cisco-dev2dev
_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public