aboutsummaryrefslogtreecommitdiff
path: root/lstring.h
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2020-01-31 11:09:53 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2020-01-31 11:09:53 -0300
commit46c3587a6feb28e1ee4a32aabe463b0ecb9e8f5e (patch)
tree7e1ae9b55536171511506532a04f4ebe6dc764b0 /lstring.h
parent69c7139ff88bf26e05d80bf19d0351e5c88d13a3 (diff)
downloadlua-46c3587a6feb28e1ee4a32aabe463b0ecb9e8f5e.tar.gz
lua-46c3587a6feb28e1ee4a32aabe463b0ecb9e8f5e.tar.bz2
lua-46c3587a6feb28e1ee4a32aabe463b0ecb9e8f5e.zip
Clearer distinction between types and tags
LUA_T* represents only types; tags (types + Variants) are represented by LUA_V* constants.
Diffstat (limited to 'lstring.h')
-rw-r--r--lstring.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/lstring.h b/lstring.h
index b2550218..c23d6874 100644
--- a/lstring.h
+++ b/lstring.h
@@ -28,13 +28,13 @@
28/* 28/*
29** test whether a string is a reserved word 29** test whether a string is a reserved word
30*/ 30*/
31#define isreserved(s) ((s)->tt == LUA_TSHRSTR && (s)->extra > 0) 31#define isreserved(s) ((s)->tt == LUA_VSHRSTR && (s)->extra > 0)
32 32
33 33
34/* 34/*
35** equality for short strings, which are always internalized 35** equality for short strings, which are always internalized
36*/ 36*/
37#define eqshrstr(a,b) check_exp((a)->tt == LUA_TSHRSTR, (a) == (b)) 37#define eqshrstr(a,b) check_exp((a)->tt == LUA_VSHRSTR, (a) == (b))
38 38
39 39
40LUAI_FUNC unsigned int luaS_hash (const char *str, size_t l, unsigned int seed); 40LUAI_FUNC unsigned int luaS_hash (const char *str, size_t l, unsigned int seed);