aboutsummaryrefslogtreecommitdiff
path: root/llimits.h
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2019-04-04 11:45:26 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2019-04-04 11:45:26 -0300
commit5ca1075b714e825006e8ba4f8e7ea5544879bb41 (patch)
treead085afa58f29e8e96071ae88c1e6e1dd73e0750 /llimits.h
parent38425e069243fe6d991f2e99b4bba192af3563c7 (diff)
downloadlua-5ca1075b714e825006e8ba4f8e7ea5544879bb41.tar.gz
lua-5ca1075b714e825006e8ba4f8e7ea5544879bb41.tar.bz2
lua-5ca1075b714e825006e8ba4f8e7ea5544879bb41.zip
Added field 'srclen' to structure 'lua_Debug'
This new field gets the length of 'source' in the same structure. Unlike the other strings in that structure, 'source' can be relatively large, and Lua already has its length readily available.
Diffstat (limited to 'llimits.h')
-rw-r--r--llimits.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/llimits.h b/llimits.h
index 3df873db..cc983972 100644
--- a/llimits.h
+++ b/llimits.h
@@ -65,6 +65,10 @@ typedef signed char ls_byte;
65#define ispow2(x) (((x) & ((x) - 1)) == 0) 65#define ispow2(x) (((x) & ((x) - 1)) == 0)
66 66
67 67
68/* number of chars of a literal string without the ending \0 */
69#define LL(x) (sizeof(x)/sizeof(char) - 1)
70
71
68/* 72/*
69** conversion of pointer to unsigned integer: 73** conversion of pointer to unsigned integer:
70** this is for hashing only; there is no problem if the integer 74** this is for hashing only; there is no problem if the integer