fix(wasm): define UINT64_MAX and update UINTPTR_MAX for wasm32/wasm64
This commit is contained in:
parent
1132e9fa28
commit
caebb72411
1 changed files with 4 additions and 0 deletions
|
|
@ -27,12 +27,16 @@ typedef long unsigned int uintptr_t;
|
|||
|
||||
#define UINT32_MAX 4294967295U
|
||||
|
||||
#define UINT64_MAX 18446744073709551615ULL
|
||||
|
||||
#if defined(__wasm32__)
|
||||
|
||||
#define UINTPTR_MAX UINT32_MAX
|
||||
#define SIZE_MAX 4294967295UL
|
||||
|
||||
#elif defined(__wasm64__)
|
||||
|
||||
#define UINTPTR_MAX UINT64_MAX
|
||||
#define SIZE_MAX 18446744073709551615UL
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue