diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2025-01-14 16:24:46 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2025-01-14 16:24:46 -0300 |
commit | 3cdd49c94a8feed94853ba3a6adaa556fb34fd8d (patch) | |
tree | 1f552c966d1fb5f5c23e956e6d98679f02a558b3 /lmem.h | |
parent | 10e931da82268a9d190c17a9bdb9b1a4b48c2947 (diff) | |
download | lua-3cdd49c94a8feed94853ba3a6adaa556fb34fd8d.tar.gz lua-3cdd49c94a8feed94853ba3a6adaa556fb34fd8d.tar.bz2 lua-3cdd49c94a8feed94853ba3a6adaa556fb34fd8d.zip |
Fixed conversion warnings from clang
Plus some other details. (Option '-Wuninitialized' was removed from
the makefile because it is already enabled by -Wall.)
Diffstat (limited to 'lmem.h')
-rw-r--r-- | lmem.h | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -39,11 +39,11 @@ | |||
39 | ** Computes the minimum between 'n' and 'MAX_SIZET/sizeof(t)', so that | 39 | ** Computes the minimum between 'n' and 'MAX_SIZET/sizeof(t)', so that |
40 | ** the result is not larger than 'n' and cannot overflow a 'size_t' | 40 | ** the result is not larger than 'n' and cannot overflow a 'size_t' |
41 | ** when multiplied by the size of type 't'. (Assumes that 'n' is an | 41 | ** when multiplied by the size of type 't'. (Assumes that 'n' is an |
42 | ** 'int' or 'unsigned int' and that 'int' is not larger than 'size_t'.) | 42 | ** 'int' and that 'int' is not larger than 'size_t'.) |
43 | */ | 43 | */ |
44 | #define luaM_limitN(n,t) \ | 44 | #define luaM_limitN(n,t) \ |
45 | ((cast_sizet(n) <= MAX_SIZET/sizeof(t)) ? (n) : \ | 45 | ((cast_sizet(n) <= MAX_SIZET/sizeof(t)) ? (n) : \ |
46 | cast_uint((MAX_SIZET/sizeof(t)))) | 46 | cast_int((MAX_SIZET/sizeof(t)))) |
47 | 47 | ||
48 | 48 | ||
49 | /* | 49 | /* |