summaryrefslogtreecommitdiff
path: root/nasmlib.c
diff options
context:
space:
mode:
authorCyrill Gorcunov <gorcunov@gmail.com>2010-01-24 15:15:21 +0300
committerCyrill Gorcunov <gorcunov@gmail.com>2010-01-24 21:28:28 +0300
commitf9958faaea11189cc84d99ef373d2cbfa66ca485 (patch)
tree820888cea9652d601265a424e6c3b2d55f40cf9f /nasmlib.c
parent75764da5dc30f06bedf15ecf1e2a24c2f70a7aaf (diff)
downloadnasm-f9958faaea11189cc84d99ef373d2cbfa66ca485.tar.gz
nasm-f9958faaea11189cc84d99ef373d2cbfa66ca485.tar.bz2
nasm-f9958faaea11189cc84d99ef373d2cbfa66ca485.zip
nasmlib.c: Use UINT64_C for 64bit constants
In a sake of portability we should better use UINT64_C instead of open-coded ULL postfix. [ BR2938449 ] Reported-by: Alexander Ilyin <dragity@mail.ru> Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Diffstat (limited to 'nasmlib.c')
-rw-r--r--nasmlib.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/nasmlib.c b/nasmlib.c
index b4ca34e..22d3b62 100644
--- a/nasmlib.c
+++ b/nasmlib.c
@@ -381,7 +381,7 @@ int64_t readnum(char *str, bool *error)
* cheat: since we know that all radices we use are even, we
* can divide 2**63 by radix/2 instead.
*/
- checklimit = 0x8000000000000000ULL / (radix >> 1);
+ checklimit = UINT64_C(0x8000000000000000) / (radix >> 1);
/*
* Calculate the highest allowable value for the last digit of a
@@ -425,7 +425,7 @@ int64_t readstrnum(char *str, int length, bool *warn)
str += length;
if (globalbits == 64) {
for (i = 0; i < length; i++) {
- if (charconst & 0xFF00000000000000ULL)
+ if (charconst & UINT64_C(0xFF00000000000000))
*warn = true;
charconst = (charconst << 8) + (uint8_t)*--str;
}