diff options
Diffstat (limited to 'src/lj_errmsg.h')
| -rw-r--r-- | src/lj_errmsg.h | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/src/lj_errmsg.h b/src/lj_errmsg.h index 23042720..daf7fb6b 100644 --- a/src/lj_errmsg.h +++ b/src/lj_errmsg.h | |||
| @@ -67,6 +67,7 @@ ERRDEF(PROTMT, "cannot change a protected metatable") | |||
| 67 | ERRDEF(UNPACK, "too many results to unpack") | 67 | ERRDEF(UNPACK, "too many results to unpack") |
| 68 | ERRDEF(RDRSTR, "reader function must return a string") | 68 | ERRDEF(RDRSTR, "reader function must return a string") |
| 69 | ERRDEF(PRTOSTR, LUA_QL("tostring") " must return a string to " LUA_QL("print")) | 69 | ERRDEF(PRTOSTR, LUA_QL("tostring") " must return a string to " LUA_QL("print")) |
| 70 | ERRDEF(NUMRNG, "number out of range") | ||
| 70 | ERRDEF(IDXRNG, "index out of range") | 71 | ERRDEF(IDXRNG, "index out of range") |
| 71 | ERRDEF(BASERNG, "base out of range") | 72 | ERRDEF(BASERNG, "base out of range") |
| 72 | ERRDEF(LVLRNG, "level out of range") | 73 | ERRDEF(LVLRNG, "level out of range") |
| @@ -78,6 +79,7 @@ ERRDEF(SETFENV, LUA_QL("setfenv") " cannot change environment of given object") | |||
| 78 | ERRDEF(CORUN, "cannot resume running coroutine") | 79 | ERRDEF(CORUN, "cannot resume running coroutine") |
| 79 | ERRDEF(CODEAD, "cannot resume dead coroutine") | 80 | ERRDEF(CODEAD, "cannot resume dead coroutine") |
| 80 | ERRDEF(COSUSP, "cannot resume non-suspended coroutine") | 81 | ERRDEF(COSUSP, "cannot resume non-suspended coroutine") |
| 82 | ERRDEF(PRNGSD, "PRNG seeding failed") | ||
| 81 | ERRDEF(TABINS, "wrong number of arguments to " LUA_QL("insert")) | 83 | ERRDEF(TABINS, "wrong number of arguments to " LUA_QL("insert")) |
| 82 | ERRDEF(TABCAT, "invalid value (%s) at index %d in table for " LUA_QL("concat")) | 84 | ERRDEF(TABCAT, "invalid value (%s) at index %d in table for " LUA_QL("concat")) |
| 83 | ERRDEF(TABSORT, "invalid order function for sorting") | 85 | ERRDEF(TABSORT, "invalid order function for sorting") |
| @@ -96,18 +98,12 @@ ERRDEF(STRPATX, "pattern too complex") | |||
| 96 | ERRDEF(STRCAPI, "invalid capture index") | 98 | ERRDEF(STRCAPI, "invalid capture index") |
| 97 | ERRDEF(STRCAPN, "too many captures") | 99 | ERRDEF(STRCAPN, "too many captures") |
| 98 | ERRDEF(STRCAPU, "unfinished capture") | 100 | ERRDEF(STRCAPU, "unfinished capture") |
| 99 | ERRDEF(STRFMTO, "invalid option " LUA_QL("%%%c") " to " LUA_QL("format")) | 101 | ERRDEF(STRFMT, "invalid option " LUA_QS " to " LUA_QL("format")) |
| 100 | ERRDEF(STRFMTR, "invalid format (repeated flags)") | ||
| 101 | ERRDEF(STRFMTW, "invalid format (width or precision too long)") | ||
| 102 | ERRDEF(STRGSRV, "invalid replacement value (a %s)") | 102 | ERRDEF(STRGSRV, "invalid replacement value (a %s)") |
| 103 | ERRDEF(BADMODN, "name conflict for module " LUA_QS) | 103 | ERRDEF(BADMODN, "name conflict for module " LUA_QS) |
| 104 | #if LJ_HASJIT | 104 | #if LJ_HASJIT |
| 105 | ERRDEF(JITPROT, "runtime code generation failed, restricted kernel?") | 105 | ERRDEF(JITPROT, "runtime code generation failed, restricted kernel?") |
| 106 | #if LJ_TARGET_X86ORX64 | ||
| 107 | ERRDEF(NOJIT, "JIT compiler disabled, CPU does not support SSE2") | ||
| 108 | #else | ||
| 109 | ERRDEF(NOJIT, "JIT compiler disabled") | 106 | ERRDEF(NOJIT, "JIT compiler disabled") |
| 110 | #endif | ||
| 111 | #elif defined(LJ_ARCH_NOJIT) | 107 | #elif defined(LJ_ARCH_NOJIT) |
| 112 | ERRDEF(NOJIT, "no JIT compiler for this architecture (yet)") | 108 | ERRDEF(NOJIT, "no JIT compiler for this architecture (yet)") |
| 113 | #else | 109 | #else |
| @@ -118,7 +114,6 @@ ERRDEF(JITOPT, "unknown or malformed optimization flag " LUA_QS) | |||
| 118 | /* Lexer/parser errors. */ | 114 | /* Lexer/parser errors. */ |
| 119 | ERRDEF(XMODE, "attempt to load chunk with wrong mode") | 115 | ERRDEF(XMODE, "attempt to load chunk with wrong mode") |
| 120 | ERRDEF(XNEAR, "%s near " LUA_QS) | 116 | ERRDEF(XNEAR, "%s near " LUA_QS) |
| 121 | ERRDEF(XELEM, "lexical element too long") | ||
| 122 | ERRDEF(XLINES, "chunk has too many lines") | 117 | ERRDEF(XLINES, "chunk has too many lines") |
| 123 | ERRDEF(XLEVELS, "chunk has too many syntax levels") | 118 | ERRDEF(XLEVELS, "chunk has too many syntax levels") |
| 124 | ERRDEF(XNUMBER, "malformed number") | 119 | ERRDEF(XNUMBER, "malformed number") |
| @@ -186,6 +181,19 @@ ERRDEF(FFI_NYIPACKBIT, "NYI: packed bit fields") | |||
| 186 | ERRDEF(FFI_NYICALL, "NYI: cannot call this C function (yet)") | 181 | ERRDEF(FFI_NYICALL, "NYI: cannot call this C function (yet)") |
| 187 | #endif | 182 | #endif |
| 188 | 183 | ||
| 184 | #if LJ_HASBUFFER | ||
| 185 | /* String buffer errors. */ | ||
| 186 | ERRDEF(BUFFER_SELF, "cannot put buffer into itself") | ||
| 187 | ERRDEF(BUFFER_BADOPT, "bad options table") | ||
| 188 | ERRDEF(BUFFER_BADENC, "cannot serialize " LUA_QS) | ||
| 189 | ERRDEF(BUFFER_BADDEC, "cannot deserialize tag 0x%02x") | ||
| 190 | ERRDEF(BUFFER_BADDICTX, "cannot deserialize dictionary index %d") | ||
| 191 | ERRDEF(BUFFER_DEPTH, "too deep to serialize") | ||
| 192 | ERRDEF(BUFFER_DUPKEY, "duplicate table key") | ||
| 193 | ERRDEF(BUFFER_EOB, "unexpected end of buffer") | ||
| 194 | ERRDEF(BUFFER_LEFTOV, "left-over data in buffer") | ||
| 195 | #endif | ||
| 196 | |||
| 189 | #undef ERRDEF | 197 | #undef ERRDEF |
| 190 | 198 | ||
| 191 | /* Detecting unused error messages: | 199 | /* Detecting unused error messages: |
