aboutsummaryrefslogtreecommitdiff
path: root/lmem.h
diff options
context:
space:
mode:
Diffstat (limited to 'lmem.h')
-rw-r--r--lmem.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/lmem.h b/lmem.h
index 204ce3bc..08358592 100644
--- a/lmem.h
+++ b/lmem.h
@@ -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/*