diff options
author | Jens Hamisch <jens@Strawberry.COM> | 2000-11-14 20:16:23 +0100 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2000-11-15 02:20:12 +0000 |
commit | a75342657dcf400110410b3b8e31c7472d01f9be (patch) | |
tree | b15e7fde02e6a43a8aeec8f77d661f9914a8c8da /utf8.h | |
parent | 819f2165639538d624797bbb9e3967a2a407beef (diff) | |
download | perl-a75342657dcf400110410b3b8e31c7472d01f9be.tar.gz |
Use UINT64_C().
Subject: [ID 20001114.006] 5.7.0-7680 Solaris 8, 64 bit, utf8 patch
Message-Id: <20001114191623.G20559@Strawberry.COM>
p4raw-id: //depot/perl@7691
Diffstat (limited to 'utf8.h')
-rw-r--r-- | utf8.h | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -9,6 +9,8 @@ START_EXTERN_C +#include "handy.h" + #ifdef DOINIT EXTCONST unsigned char PL_utf8skip[] = { 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, /* ascii */ @@ -48,6 +50,8 @@ END_EXTERN_C #define UTF8SKIP(s) PL_utf8skip[*(U8*)s] +#define UTF8_QUAD_MAX UINT64_C(0x1000000000) + #ifdef HAS_QUAD #define UNISKIP(uv) ( (uv) < 0x80 ? 1 : \ (uv) < 0x800 ? 2 : \ @@ -55,7 +59,7 @@ END_EXTERN_C (uv) < 0x200000 ? 4 : \ (uv) < 0x4000000 ? 5 : \ (uv) < 0x80000000 ? 6 : \ - (uv) < 0x1000000000LL ? 7 : 13 ) + (uv) < UTF8_QUAD_MAX ? 7 : 13 ) #else /* No, I'm not even going to *TRY* putting #ifdef inside a #define */ #define UNISKIP(uv) ( (uv) < 0x80 ? 1 : \ |