diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2019-02-20 10:13:46 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2019-02-20 10:13:46 -0300 |
commit | e08e5df853560de6482d84066a7accc6a18de545 (patch) | |
tree | ee19686bb35da90709a32ed24bf7855de1a3946a /lpprint.h | |
download | lpeg-e08e5df853560de6482d84066a7accc6a18de545.tar.gz lpeg-e08e5df853560de6482d84066a7accc6a18de545.tar.bz2 lpeg-e08e5df853560de6482d84066a7accc6a18de545.zip |
Fist version of LPeg on GIT
LPeg repository is being moved to git. Past versions won't be moved;
they are still available in RCS.
Diffstat (limited to 'lpprint.h')
-rw-r--r-- | lpprint.h | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/lpprint.h b/lpprint.h new file mode 100644 index 0000000..6329760 --- /dev/null +++ b/lpprint.h | |||
@@ -0,0 +1,36 @@ | |||
1 | /* | ||
2 | ** $Id: lpprint.h,v 1.2 2015/06/12 18:18:08 roberto Exp $ | ||
3 | */ | ||
4 | |||
5 | |||
6 | #if !defined(lpprint_h) | ||
7 | #define lpprint_h | ||
8 | |||
9 | |||
10 | #include "lptree.h" | ||
11 | #include "lpvm.h" | ||
12 | |||
13 | |||
14 | #if defined(LPEG_DEBUG) | ||
15 | |||
16 | void printpatt (Instruction *p, int n); | ||
17 | void printtree (TTree *tree, int ident); | ||
18 | void printktable (lua_State *L, int idx); | ||
19 | void printcharset (const byte *st); | ||
20 | void printcaplist (Capture *cap, Capture *limit); | ||
21 | void printinst (const Instruction *op, const Instruction *p); | ||
22 | |||
23 | #else | ||
24 | |||
25 | #define printktable(L,idx) \ | ||
26 | luaL_error(L, "function only implemented in debug mode") | ||
27 | #define printtree(tree,i) \ | ||
28 | luaL_error(L, "function only implemented in debug mode") | ||
29 | #define printpatt(p,n) \ | ||
30 | luaL_error(L, "function only implemented in debug mode") | ||
31 | |||
32 | #endif | ||
33 | |||
34 | |||
35 | #endif | ||
36 | |||