Nut/OS  4.10.3
API Reference
llex.h File Reference
#include <lua/lobject.h>
#include <lua/lzio.h>
Include dependency graph for llex.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

union  SemInfo
struct  Token
struct  LexState

Defines

#define FIRST_RESERVED   257
#define TOKEN_LEN   (sizeof("function")/sizeof(char))
#define NUM_RESERVED   (cast(int, TK_WHILE-FIRST_RESERVED+1))

Typedefs

typedef struct Token Token
typedef struct LexState LexState

Enumerations

enum  RESERVED {
  TK_AND = FIRST_RESERVED, TK_BREAK, TK_DO, TK_ELSE,
  TK_ELSEIF, TK_END, TK_FALSE, TK_FOR,
  TK_FUNCTION, TK_IF, TK_IN, TK_LOCAL,
  TK_NIL, TK_NOT, TK_OR, TK_REPEAT,
  TK_RETURN, TK_THEN, TK_TRUE, TK_UNTIL,
  TK_WHILE, TK_CONCAT, TK_DOTS, TK_EQ,
  TK_GE, TK_LE, TK_NE, TK_NUMBER,
  TK_NAME, TK_STRING, TK_EOS
}

Functions

LUAI_FUNC void luaX_init (lua_State *L)
LUAI_FUNC void luaX_setinput (lua_State *L, LexState *ls, ZIO *z, TString *source)
LUAI_FUNC TStringluaX_newstring (LexState *ls, const char *str, size_t l)
LUAI_FUNC void luaX_next (LexState *ls)
LUAI_FUNC void luaX_lookahead (LexState *ls)
LUAI_FUNC void luaX_lexerror (LexState *ls, const char *msg, int token)
LUAI_FUNC void luaX_syntaxerror (LexState *ls, const char *s)
LUAI_FUNC const char * luaX_token2str (LexState *ls, int token)

Variables

LUAI_DATA const char *const luaX_tokens []

Define Documentation

#define FIRST_RESERVED   257

Definition at line 14 of file llex.h.

#define TOKEN_LEN   (sizeof("function")/sizeof(char))

Definition at line 17 of file llex.h.

#define NUM_RESERVED   (cast(int, TK_WHILE-FIRST_RESERVED+1))

Definition at line 36 of file llex.h.


Typedef Documentation

typedef struct Token Token
typedef struct LexState LexState

Enumeration Type Documentation

enum RESERVED
Enumerator:
TK_AND 
TK_BREAK 
TK_DO 
TK_ELSE 
TK_ELSEIF 
TK_END 
TK_FALSE 
TK_FOR 
TK_FUNCTION 
TK_IF 
TK_IN 
TK_LOCAL 
TK_NIL 
TK_NOT 
TK_OR 
TK_REPEAT 
TK_RETURN 
TK_THEN 
TK_TRUE 
TK_UNTIL 
TK_WHILE 
TK_CONCAT 
TK_DOTS 
TK_EQ 
TK_GE 
TK_LE 
TK_NE 
TK_NUMBER 
TK_NAME 
TK_STRING 
TK_EOS 

Definition at line 24 of file llex.h.


Function Documentation

LUAI_FUNC void luaX_init ( lua_State L)
LUAI_FUNC void luaX_setinput ( lua_State L,
LexState ls,
ZIO z,
TString source 
)
LUAI_FUNC TString* luaX_newstring ( LexState ls,
const char *  str,
size_t  l 
)
LUAI_FUNC void luaX_next ( LexState ls)
LUAI_FUNC void luaX_lookahead ( LexState ls)
LUAI_FUNC void luaX_lexerror ( LexState ls,
const char *  msg,
int  token 
)
LUAI_FUNC void luaX_syntaxerror ( LexState ls,
const char *  s 
)
LUAI_FUNC const char* luaX_token2str ( LexState ls,
int  token 
)

Variable Documentation

LUAI_DATA const char* const luaX_tokens[]

Definition at line 40 of file llex.h.