aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/libraries/luajit-2.0/src/lj_errmsg.h
diff options
context:
space:
mode:
authorDavid Walter Seikel2012-01-23 23:36:30 +1000
committerDavid Walter Seikel2012-01-23 23:36:30 +1000
commit6523585c66c04cea54df50013df8886b589847d8 (patch)
tree0b22aee7064166d88595eda260ca2d17c0773da5 /libraries/luajit-2.0/src/lj_errmsg.h
parentUpdate the EFL to what I'm actually using, coz I'm using some stuff not yet r... (diff)
downloadSledjHamr-6523585c66c04cea54df50013df8886b589847d8.zip
SledjHamr-6523585c66c04cea54df50013df8886b589847d8.tar.gz
SledjHamr-6523585c66c04cea54df50013df8886b589847d8.tar.bz2
SledjHamr-6523585c66c04cea54df50013df8886b589847d8.tar.xz
Add luaproc and LuaJIT libraries.
Two versions of LuaJIT, the stable release, and the dev version. Try the dev version first, until ih fails badly.
Diffstat (limited to 'libraries/luajit-2.0/src/lj_errmsg.h')
-rw-r--r--libraries/luajit-2.0/src/lj_errmsg.h173
1 files changed, 173 insertions, 0 deletions
diff --git a/libraries/luajit-2.0/src/lj_errmsg.h b/libraries/luajit-2.0/src/lj_errmsg.h
new file mode 100644
index 0000000..10c8395
--- /dev/null
+++ b/libraries/luajit-2.0/src/lj_errmsg.h
@@ -0,0 +1,173 @@
1/*
2** VM error messages.
3** Copyright (C) 2005-2011 Mike Pall. See Copyright Notice in luajit.h
4*/
5
6/* This file may be included multiple times with different ERRDEF macros. */
7
8/* Basic error handling. */
9ERRDEF(ERRMEM, "not enough memory")
10ERRDEF(ERRERR, "error in error handling")
11ERRDEF(ERRCPP, "C++ exception")
12
13/* Allocations. */
14ERRDEF(STROV, "string length overflow")
15ERRDEF(UDATAOV, "userdata length overflow")
16ERRDEF(STKOV, "stack overflow")
17ERRDEF(STKOVM, "stack overflow (%s)")
18ERRDEF(TABOV, "table overflow")
19
20/* Table indexing. */
21ERRDEF(NANIDX, "table index is NaN")
22ERRDEF(NILIDX, "table index is nil")
23ERRDEF(NEXTIDX, "invalid key to " LUA_QL("next"))
24
25/* Metamethod resolving. */
26ERRDEF(BADCALL, "attempt to call a %s value")
27ERRDEF(BADOPRT, "attempt to %s %s " LUA_QS " (a %s value)")
28ERRDEF(BADOPRV, "attempt to %s a %s value")
29ERRDEF(BADCMPT, "attempt to compare %s with %s")
30ERRDEF(BADCMPV, "attempt to compare two %s values")
31ERRDEF(GETLOOP, "loop in gettable")
32ERRDEF(SETLOOP, "loop in settable")
33ERRDEF(OPCALL, "call")
34ERRDEF(OPINDEX, "index")
35ERRDEF(OPARITH, "perform arithmetic on")
36ERRDEF(OPCAT, "concatenate")
37ERRDEF(OPLEN, "get length of")
38
39/* Type checks. */
40ERRDEF(BADSELF, "calling " LUA_QS " on bad self (%s)")
41ERRDEF(BADARG, "bad argument #%d to " LUA_QS " (%s)")
42ERRDEF(BADTYPE, "%s expected, got %s")
43ERRDEF(BADVAL, "invalid value")
44ERRDEF(NOVAL, "value expected")
45ERRDEF(NOCORO, "coroutine expected")
46ERRDEF(NOTABN, "nil or table expected")
47ERRDEF(NOFUNCL, "function or level expected")
48ERRDEF(NOSFT, "string/function/table expected")
49ERRDEF(NOPROXY, "boolean or proxy expected")
50ERRDEF(FORINIT, LUA_QL("for") " initial value must be a number")
51ERRDEF(FORLIM, LUA_QL("for") " limit must be a number")
52ERRDEF(FORSTEP, LUA_QL("for") " step must be a number")
53
54/* C API checks. */
55ERRDEF(NOENV, "no calling environment")
56ERRDEF(CYIELD, "attempt to yield across C-call boundary")
57ERRDEF(BADLU, "bad light userdata pointer")
58ERRDEF(NOGCMM, "bad action while in __gc metamethod")
59#if LJ_TARGET_WINDOWS
60ERRDEF(BADFPU, "bad FPU precision (use D3DCREATE_FPU_PRESERVE with DirectX)")
61#endif
62
63/* Standard library function errors. */
64ERRDEF(ASSERT, "assertion failed!")
65ERRDEF(PROTMT, "cannot change a protected metatable")
66ERRDEF(UNPACK, "too many results to unpack")
67ERRDEF(RDRSTR, "reader function must return a string")
68ERRDEF(PRTOSTR, LUA_QL("tostring") " must return a string to " LUA_QL("print"))
69ERRDEF(IDXRNG, "index out of range")
70ERRDEF(BASERNG, "base out of range")
71ERRDEF(LVLRNG, "level out of range")
72ERRDEF(INVLVL, "invalid level")
73ERRDEF(INVOPT, "invalid option")
74ERRDEF(INVOPTM, "invalid option " LUA_QS)
75ERRDEF(INVFMT, "invalid format")
76ERRDEF(SETFENV, LUA_QL("setfenv") " cannot change environment of given object")
77ERRDEF(CORUN, "cannot resume running coroutine")
78ERRDEF(CODEAD, "cannot resume dead coroutine")
79ERRDEF(COSUSP, "cannot resume non-suspended coroutine")
80ERRDEF(TABINS, "wrong number of arguments to " LUA_QL("insert"))
81ERRDEF(TABCAT, "invalid value (%s) at index %d in table for " LUA_QL("concat"))
82ERRDEF(TABSORT, "invalid order function for sorting")
83ERRDEF(IOCLFL, "attempt to use a closed file")
84ERRDEF(IOSTDCL, "standard file is closed")
85ERRDEF(OSUNIQF, "unable to generate a unique filename")
86ERRDEF(OSDATEF, "field " LUA_QS " missing in date table")
87ERRDEF(STRDUMP, "unable to dump given function")
88ERRDEF(STRSLC, "string slice too long")
89ERRDEF(STRPATB, "missing " LUA_QL("[") " after " LUA_QL("%f") " in pattern")
90ERRDEF(STRPATC, "invalid pattern capture")
91ERRDEF(STRPATE, "malformed pattern (ends with " LUA_QL("%") ")")
92ERRDEF(STRPATM, "malformed pattern (missing " LUA_QL("]") ")")
93ERRDEF(STRPATU, "unbalanced pattern")
94ERRDEF(STRCAPI, "invalid capture index")
95ERRDEF(STRCAPN, "too many captures")
96ERRDEF(STRCAPU, "unfinished capture")
97ERRDEF(STRFMTO, "invalid option " LUA_QL("%%%c") " to " LUA_QL("format"))
98ERRDEF(STRFMTR, "invalid format (repeated flags)")
99ERRDEF(STRFMTW, "invalid format (width or precision too long)")
100ERRDEF(STRGSRV, "invalid replacement value (a %s)")
101ERRDEF(BADMODN, "name conflict for module " LUA_QS)
102#if LJ_HASJIT
103ERRDEF(NOJIT, "JIT compiler disabled, CPU does not support SSE2")
104#elif defined(LJ_ARCH_NOJIT)
105ERRDEF(NOJIT, "no JIT compiler for this architecture (yet)")
106#else
107ERRDEF(NOJIT, "JIT compiler permanently disabled by build option")
108#endif
109ERRDEF(JITOPT, "unknown or malformed optimization flag " LUA_QS)
110
111/* Lexer/parser errors. */
112ERRDEF(XNEAR, "%s near " LUA_QS)
113ERRDEF(XELEM, "lexical element too long")
114ERRDEF(XLINES, "chunk has too many lines")
115ERRDEF(XLEVELS, "chunk has too many syntax levels")
116ERRDEF(XNUMBER, "malformed number")
117ERRDEF(XLSTR, "unfinished long string")
118ERRDEF(XLCOM, "unfinished long comment")
119ERRDEF(XSTR, "unfinished string")
120ERRDEF(XESC, "invalid escape sequence")
121ERRDEF(XLDELIM, "invalid long string delimiter")
122ERRDEF(XTOKEN, LUA_QS " expected")
123ERRDEF(XJUMP, "control structure too long")
124ERRDEF(XSLOTS, "function or expression too complex")
125ERRDEF(XLIMC, "chunk has more than %d local variables")
126ERRDEF(XLIMM, "main function has more than %d %s")
127ERRDEF(XLIMF, "function at line %d has more than %d %s")
128ERRDEF(XMATCH, LUA_QS " expected (to close " LUA_QS " at line %d)")
129ERRDEF(XFIXUP, "function too long for return fixup")
130ERRDEF(XPARAM, "<name> or " LUA_QL("...") " expected")
131ERRDEF(XAMBIG, "ambiguous syntax (function call x new statement)")
132ERRDEF(XFUNARG, "function arguments expected")
133ERRDEF(XSYMBOL, "unexpected symbol")
134ERRDEF(XDOTS, "cannot use " LUA_QL("...") " outside a vararg function")
135ERRDEF(XSYNTAX, "syntax error")
136ERRDEF(XBREAK, "no loop to break")
137ERRDEF(XFOR, LUA_QL("=") " or " LUA_QL("in") " expected")
138
139/* Bytecode reader errors. */
140ERRDEF(BCFMT, "cannot load incompatible bytecode")
141ERRDEF(BCBAD, "cannot load malformed bytecode")
142
143#if LJ_HASFFI
144/* FFI errors. */
145ERRDEF(FFI_INVTYPE, "invalid C type")
146ERRDEF(FFI_INVSIZE, "size of C type is unknown or too large")
147ERRDEF(FFI_BADSCL, "bad storage class")
148ERRDEF(FFI_DECLSPEC, "declaration specifier expected")
149ERRDEF(FFI_BADTAG, "undeclared or implicit tag " LUA_QS)
150ERRDEF(FFI_REDEF, "attempt to redefine " LUA_QS)
151ERRDEF(FFI_INITOV, "too many initializers for " LUA_QS)
152ERRDEF(FFI_BADCONV, "cannot convert " LUA_QS " to " LUA_QS)
153ERRDEF(FFI_BADLEN, "attempt to get length of " LUA_QS)
154ERRDEF(FFI_BADCONCAT, "attempt to concatenate " LUA_QS " and " LUA_QS)
155ERRDEF(FFI_BADARITH, "attempt to perform arithmetic on " LUA_QS " and " LUA_QS)
156ERRDEF(FFI_BADCOMP, "attempt to compare " LUA_QS " with " LUA_QS)
157ERRDEF(FFI_BADCALL, LUA_QS " is not callable")
158ERRDEF(FFI_NUMARG, "wrong number of arguments for function call")
159ERRDEF(FFI_BADMEMBER, LUA_QS " has no member named " LUA_QS)
160ERRDEF(FFI_BADIDX, LUA_QS " cannot be indexed")
161ERRDEF(FFI_WRCONST, "attempt to write to constant location")
162ERRDEF(FFI_NODECL, "missing declaration for symbol " LUA_QS)
163ERRDEF(FFI_BADCBACK, "bad callback")
164ERRDEF(FFI_CBACKOV, "too many callbacks")
165ERRDEF(FFI_NYIPACKBIT, "NYI: packed bit fields")
166ERRDEF(FFI_NYICALL, "NYI: cannot call this C function (yet)")
167#endif
168
169#undef ERRDEF
170
171/* Detecting unused error messages:
172 awk -F, '/^ERRDEF/ { gsub(/ERRDEF./, ""); printf "grep -q LJ_ERR_%s *.[ch] || echo %s\n", $1, $1}' lj_errmsg.h | sh
173*/