Allow base destructors to run and fix some error reporting.
This commit is contained in:
parent
63ad5eff18
commit
861953d736
@ -3434,7 +3434,7 @@ methodmap_method_t *parse_method(methodmap_t *map)
|
||||
if (is_bind) {
|
||||
target = findglb(bindname, sGLOBAL);
|
||||
if (!target)
|
||||
error(17, ident);
|
||||
error(17, bindname);
|
||||
else if (target->ident != iFUNCTN)
|
||||
error(10);
|
||||
} else {
|
||||
@ -3645,7 +3645,18 @@ static void dodelete()
|
||||
return;
|
||||
}
|
||||
|
||||
if (!map->dtor) {
|
||||
{
|
||||
methodmap_t *iter = map;
|
||||
while (iter) {
|
||||
if (iter->dtor) {
|
||||
map = iter;
|
||||
break;
|
||||
}
|
||||
iter = iter->parent;
|
||||
}
|
||||
}
|
||||
|
||||
if (!map || !map->dtor) {
|
||||
error(115, layout_spec_name(map->spec), map->name);
|
||||
return;
|
||||
}
|
||||
|
@ -1,407 +1,407 @@
|
||||
/* Pawn compiler - Error message strings (plain and compressed formats)
|
||||
*
|
||||
* Copyright (c) ITB CompuPhase, 2000-2006
|
||||
*
|
||||
* This software is provided "as-is", without any express or implied warranty.
|
||||
* In no event will the authors be held liable for any damages arising from
|
||||
* the use of this software.
|
||||
*
|
||||
* Permission is granted to anyone to use this software for any purpose,
|
||||
* including commercial applications, and to alter it and redistribute it
|
||||
* freely, subject to the following restrictions:
|
||||
*
|
||||
* 1. The origin of this software must not be misrepresented; you must not
|
||||
* claim that you wrote the original software. If you use this software in
|
||||
* a product, an acknowledgment in the product documentation would be
|
||||
* appreciated but is not required.
|
||||
* 2. Altered source versions must be plainly marked as such, and must not be
|
||||
* misrepresented as being the original software.
|
||||
* 3. This notice may not be removed or altered from any source distribution.
|
||||
*
|
||||
* Version: $Id$
|
||||
*/
|
||||
|
||||
SC_FUNC int strexpand(char *dest, unsigned char *source, int maxlen, unsigned char pairtable[128][2]);
|
||||
|
||||
#ifndef SCPACK
|
||||
# define SCPACK
|
||||
# define SCPACK_PUSH
|
||||
#endif
|
||||
|
||||
#define SCPACK_TABLE errstr_table
|
||||
/* Pawn compiler - Error message strings (plain and compressed formats)
|
||||
*
|
||||
* Copyright (c) ITB CompuPhase, 2000-2006
|
||||
*
|
||||
* This software is provided "as-is", without any express or implied warranty.
|
||||
* In no event will the authors be held liable for any damages arising from
|
||||
* the use of this software.
|
||||
*
|
||||
* Permission is granted to anyone to use this software for any purpose,
|
||||
* including commercial applications, and to alter it and redistribute it
|
||||
* freely, subject to the following restrictions:
|
||||
*
|
||||
* 1. The origin of this software must not be misrepresented; you must not
|
||||
* claim that you wrote the original software. If you use this software in
|
||||
* a product, an acknowledgment in the product documentation would be
|
||||
* appreciated but is not required.
|
||||
* 2. Altered source versions must be plainly marked as such, and must not be
|
||||
* misrepresented as being the original software.
|
||||
* 3. This notice may not be removed or altered from any source distribution.
|
||||
*
|
||||
* Version: $Id$
|
||||
*/
|
||||
|
||||
SC_FUNC int strexpand(char *dest, unsigned char *source, int maxlen, unsigned char pairtable[128][2]);
|
||||
|
||||
#ifndef SCPACK
|
||||
# define SCPACK
|
||||
# define SCPACK_PUSH
|
||||
#endif
|
||||
|
||||
#define SCPACK_TABLE errstr_table
|
||||
/*-*SCPACK start of pair table, do not change or remove this line */
|
||||
unsigned char errstr_table[][2] = {
|
||||
{101,32}, {116,32}, {111,110}, {105,110}, {115,32}, {97,114}, {100,32}, {116,105}, {37,115}, {101,114}, {101,110}, {97,108}, {135,130}, {110,111}, {34,136}, {142,34},
|
||||
{117,110}, {114,101}, {111,114}, {97,110}, {121,32}, {115,116}, {100,101}, {115,105}, {97,116}, {141,129}, {32,143}, {109,98}, {109,138}, {41,10}, {101,134}, {140,32},
|
||||
{116,104}, {98,108}, {144,99}, {102,162}, {114,97}, {111,108}, {117,115}, {146,32}, {118,139}, {97,32}, {115,121}, {170,155}, {171,165}, {103,32}, {137,32}, {103,117},
|
||||
{101,120}, {175,156}, {133,164}, {133,177}, {102,131}, {105,134}, {115,151}, {97,161}, {99,104}, {163,159}, {168,181}, {111,102}, {105,132}, {115,10}, {131,186}, {101,100},
|
||||
{166,129}, {101,132}, {172,154}, {109,192}, {98,128}, {99,130}, {118,133}, {99,147}, {187,32}, {105,183}, {198,201}, {104,97}, {109,97}, {116,111}, {112,145}, {178,148},
|
||||
{199,153}, {150,180}, {116,97}, {109,101}, {99,116}, {179,129}, {130,32}, {133,97}, {149,152}, {44,32}, {102,105}, {118,128}, {154,10}, {101,10}, {109,152}, {194,157},
|
||||
{110,32}, {40,223}, {100,105}, {119,105}, {117,108}, {99,111}, {97,115}, {202,128}, {136,10}, {197,149}, {34,32}, {139,32}, {151,122}, {98,101}, {108,111}, {111,112},
|
||||
{108,128}, {163,140}, {102,146}, {131,32}, {147,32}, {160,32}, {210,173}, {131,173}, {222,184}, {195,196}, {203,219}, {58,220}, {100,111}, {109,112}, {160,128}
|
||||
unsigned char errstr_table
[][2] = {
|
||||
{101,32}, {116,32}, {111,110}, {115,32}, {105,110}, {97,114}, {100,32}, {116,105}, {37,115}, {101,114}, {101,110}, {97,108}, {110,111}, {135,130}, {34,136}, {142,34},
|
||||
{117,110}, {111,114}, {114,101}, {97,110}, {121,32}, {115,116}, {100,101}, {115,105}, {97,116}, {140,129}, {32,143}, {109,98}, {109,138}, {41,10}, {101,134}, {141,32},
|
||||
{98,108}, {144,99}, {116,104}, {102,161}, {114,97}, {111,108}, {117,115}, {145,32}, {118,139}, {97,32}, {115,121}, {170,155}, {171,165}, {103,32}, {137,32}, {103,117},
|
||||
{101,120}, {175,156}, {133,164}, {133,177}, {102,132}, {105,134}, {115,151}, {97,160}, {99,104}, {163,159}, {168,181}, {111,102}, {105,131}, {115,10}, {132,186}, {101,100},
|
||||
{101,131}, {166,129}, {172,154}, {109,193}, {104,97}, {99,130}, {118,133}, {99,147}, {187,32}, {105,183}, {198,201}, {109,97}, {116,111}, {99,116}, {98,128}, {112,146},
|
||||
{178,148}, {199,153}, {150,180}, {116,97}, {109,101}, {179,129}, {44,32}, {130,32}, {133,97}, {149,152}, {102,105}, {118,128}, {154,10}, {101,10}, {109,152}, {194,157},
|
||||
{110,32}, {40,223}, {100,105}, {117,108}, {99,111}, {97,115}, {202,128}, {197,149}, {34,32}, {139,32}, {119,105}, {151,122}, {136,10}, {98,101}, {108,111}, {111,112},
|
||||
{108,128}, {163,141}, {102,145}, {132,32}, {140,32}, {147,32}, {211,173}, {132,173}, {222,184}, {195,206}, {196,219}, {58,220}, {100,111}, {149,114}, {109,112}
|
||||
};
|
||||
/*-*SCPACK end of pair table, do not change or remove this line */
|
||||
|
||||
static char *errmsg[] = {
|
||||
#ifdef SCPACK
|
||||
/*001*/ "expected token: \"%s\", but found \"%s\"\n",
|
||||
/*002*/ "only a single statement (or expression) can follow each \"case\"\n",
|
||||
/*003*/ "declaration of a local variable must appear in a compound block\n",
|
||||
/*004*/ "function \"%s\" is not implemented\n",
|
||||
/*005*/ "function may not have arguments\n",
|
||||
/*006*/ "must be assigned to an array\n",
|
||||
/*007*/ "operator cannot be redefined\n",
|
||||
/*008*/ "must be a constant expression; assumed zero\n",
|
||||
/*009*/ "invalid array size (negative, zero or out of bounds)\n",
|
||||
/*010*/ "invalid function or declaration\n",
|
||||
/*011*/ "invalid outside functions\n",
|
||||
/*012*/ "invalid function call, not a valid address\n",
|
||||
/*013*/ "no entry point (no public functions)\n",
|
||||
/*014*/ "invalid statement; not in switch\n",
|
||||
/*015*/ "\"default\" case must be the last case in switch statement\n",
|
||||
/*016*/ "multiple defaults in \"switch\"\n",
|
||||
/*017*/ "undefined symbol \"%s\"\n",
|
||||
/*018*/ "initialization data exceeds declared size\n",
|
||||
/*019*/ "not a label: \"%s\"\n",
|
||||
/*020*/ "invalid symbol name \"%s\"\n",
|
||||
/*021*/ "symbol already defined: \"%s\"\n",
|
||||
/*022*/ "must be lvalue (non-constant)\n",
|
||||
/*023*/ "array assignment must be simple assignment\n",
|
||||
/*024*/ "\"break\" or \"continue\" is out of context\n",
|
||||
/*025*/ "function heading differs from prototype\n",
|
||||
/*026*/ "no matching \"#if...\"\n",
|
||||
/*027*/ "invalid character constant\n",
|
||||
/*028*/ "invalid subscript (not an array or too many subscripts): \"%s\"\n",
|
||||
/*029*/ "invalid expression, assumed zero\n",
|
||||
/*030*/ "compound statement not closed at the end of file (started at line %d)\n",
|
||||
/*031*/ "unknown directive\n",
|
||||
/*032*/ "array index out of bounds (variable \"%s\")\n",
|
||||
/*033*/ "array must be indexed (variable \"%s\")\n",
|
||||
/*034*/ "argument does not have a default value (argument %d)\n",
|
||||
/*035*/ "argument type mismatch (argument %d)\n",
|
||||
/*036*/ "empty statement\n",
|
||||
/*037*/ "invalid string (possibly non-terminated string)\n",
|
||||
/*038*/ "extra characters on line\n",
|
||||
/*039*/ "constant symbol has no size\n",
|
||||
/*040*/ "duplicate \"case\" label (value %d)\n",
|
||||
/*041*/ "invalid ellipsis, array size is not known\n",
|
||||
/*042*/ "invalid combination of class specifiers\n",
|
||||
/*043*/ "character constant exceeds range for packed string\n",
|
||||
/*044*/ "positional parameters must precede all named parameters\n",
|
||||
/*045*/ "too many function arguments\n",
|
||||
/*046*/ "unknown array size (variable \"%s\")\n",
|
||||
/*047*/ "array sizes do not match, or destination array is too small\n",
|
||||
/*048*/ "array (s do not match\n",
|
||||
/*049*/ "invalid line continuation\n",
|
||||
/*050*/ "invalid range\n",
|
||||
/*051*/ "invalid subscript, use \"[ ]\" operators on major dimensions\n",
|
||||
/*052*/ "multi-dimensional arrays must be fully initialized\n",
|
||||
/*053*/ "exceeding maximum number of dimensions\n",
|
||||
/*054*/ "unmatched closing brace (\"}\")\n",
|
||||
/*055*/ "start of function body without function header\n",
|
||||
/*056*/ "arrays, local variables and function arguments cannot be public (variable \"%s\")\n",
|
||||
/*057*/ "unfinished expression before compiler directive\n",
|
||||
/*058*/ "duplicate argument; same argument is passed twice\n",
|
||||
/*059*/ "function argument may not have a default value (variable \"%s\")\n",
|
||||
/*060*/ "multiple \"#else\" directives between \"#if ... #endif\"\n",
|
||||
/*061*/ "\"#elseif\" directive follows an \"#else\" directive\n",
|
||||
/*062*/ "number of operands does not fit the operator\n",
|
||||
/*063*/ "function result tag of operator \"%s\" must be \"%s\"\n",
|
||||
/*064*/ "cannot change predefined operators\n",
|
||||
/*065*/ "function argument may only have a single tag (argument %d)\n",
|
||||
/*066*/ "function argument may not be a reference argument or an array (argument \"%s\")\n",
|
||||
/*067*/ "variable cannot be both a reference and an array (variable \"%s\")\n",
|
||||
/*068*/ "invalid rational number precision in #pragma\n",
|
||||
/*069*/ "rational number format already defined\n",
|
||||
/*070*/ "rational number support was not enabled\n",
|
||||
/*071*/ "user-defined operator must be declared before use (function \"%s\")\n",
|
||||
/*072*/ "\"sizeof\" operator is invalid on \"function\" symbols\n",
|
||||
/*073*/ "function argument must be an array (argument \"%s\")\n",
|
||||
/*074*/ "#define pattern must start with an alphabetic character\n",
|
||||
/*075*/ "input line too long (after substitutions)\n",
|
||||
/*076*/ "syntax error in the expression, or invalid function call\n",
|
||||
/*077*/ "malformed UTF-8 encoding, or corrupted file: %s\n",
|
||||
/*078*/ "function uses both \"return\" and \"return <value>\"\n",
|
||||
/*079*/ "inconsistent return types (array & non-array)\n",
|
||||
/*080*/ "unknown symbol, or not a constant symbol (symbol \"%s\")\n",
|
||||
/*081*/ "cannot take a tag as a default value for an indexed array parameter (symbol \"%s\")\n",
|
||||
/*082*/ "user-defined operators and native functions may not have states\n",
|
||||
/*083*/ "a function or variable may only belong to a single automaton (symbol \"%s\")\n",
|
||||
/*084*/ "state conflict: one of the states is already assigned to another implementation (symbol \"%s\")\n",
|
||||
/*085*/ "no states are defined for symbol \"%s\"\n",
|
||||
/*086*/ "unknown automaton \"%s\"\n",
|
||||
/*087*/ "unknown state \"%s\" for automaton \"%s\"\n",
|
||||
/*088*/ "public variables and local variables may not have states (symbol \"%s\")\n",
|
||||
/*089*/ "state variables may not be initialized (symbol \"%s\")\n",
|
||||
/*090*/ "public functions may not return arrays (symbol \"%s\")\n",
|
||||
/*091*/ "ambiguous constant; tag override is required (symbol \"%s\")\n",
|
||||
/*092*/ "number of arguments does not match definition\n",
|
||||
/*093*/ "expected tag name identifier\n",
|
||||
/*094*/ "function enumeration requires unique tag\n",
|
||||
/*095*/ "cannot have required parameters after optional parameters\n",
|
||||
/*096*/ "could not find member \"%s\" in struct \"%s\"\n",
|
||||
/*097*/ "symbol \"%s\" does not have a matching type\n",
|
||||
/*098*/ "type \"%s\" should be \"%s\" in new-style declarations\n",
|
||||
/*099*/ "destructors cannot return values\n",
|
||||
/*100*/ "function prototypes do not match\n",
|
||||
/*101*/ "specify either all dimensions or only the last dimension\n",
|
||||
/*102*/ "cannot find %s %s\n",
|
||||
/*103*/ "%s was already defined on this %s\n",
|
||||
/*104*/ "cannot find any methods for %s\n",
|
||||
/*105*/ "cannot find method %s.%s\n",
|
||||
/*106*/ "cannot call methods on an array\n",
|
||||
/*107*/ "cannot call methods on a function\n",
|
||||
/*108*/ "method must have a first argument compatible with the %s type (%s)\n",
|
||||
/*109*/ "%s name must start with an uppercase letter\n",
|
||||
/*110*/ "%s has already been defined (previously seen as %s)\n",
|
||||
/*111*/ "expected identifier - did you forget a type?\n",
|
||||
/*112*/ "constructor function must return tag %s\n",
|
||||
/*113*/ "cannot define constructor for \"%s\"; already exists as a %s\n",
|
||||
/*114*/ "destructor must have the same name as %s \"%s\"\n",
|
||||
/*115*/ "delete cannot be used with %s\n",
|
||||
/*116*/ "no methodmap or class was found for %s\n",
|
||||
/*117*/ "no destructor was found for %s %s\n",
|
||||
/*118*/ "destructors must be native functions\n",
|
||||
/*119*/ "destructors cannot have extra arguments\n",
|
||||
#else
|
||||
"\260pe\324\236\315k\212:\232\331bu\201fo\220\206\217\012",
|
||||
"\202l\224\251s\203g\360\330e\234\201(\247\260\316\266\202) \307 f\245\356w ea\270 \042c\346e\042\012",
|
||||
"\226cl\327\237\310\251\356c\353\347\303appe\205 \363\251\345\375o\220\206\241ock\012",
|
||||
"\361\232 \274\231i\375le\234t\277\012",
|
||||
"\271\314\224\231\372\263t\275",
|
||||
"\371a\266gn\236\315 \364\262y\012",
|
||||
"\357\211\230\247\320\304\221\321\277\012",
|
||||
"\371\251\351\223\201\260\316\266\202; \346sum\236z\211o\012",
|
||||
"\276\317\354\200(nega\207ve\331z\211o \247ou\201\310bo\220ds\235",
|
||||
"\276\271\247\226cl\327\214\012",
|
||||
|
||||
static char *errmsg[] = {
|
||||
#ifdef SCPACK
|
||||
/*001*/ "expected token: \"%s\", but found \"%s\"\n",
|
||||
/*002*/ "only a single statement (or expression) can follow each \"case\"\n",
|
||||
/*003*/ "declaration of a local variable must appear in a compound block\n",
|
||||
/*004*/ "function \"%s\" is not implemented\n",
|
||||
/*005*/ "function may not have arguments\n",
|
||||
/*006*/ "must be assigned to an array\n",
|
||||
/*007*/ "operator cannot be redefined\n",
|
||||
/*008*/ "must be a constant expression; assumed zero\n",
|
||||
/*009*/ "invalid array size (negative, zero or out of bounds)\n",
|
||||
/*010*/ "invalid function or declaration\n",
|
||||
/*011*/ "invalid outside functions\n",
|
||||
/*012*/ "invalid function call, not a valid address\n",
|
||||
/*013*/ "no entry point (no public functions)\n",
|
||||
/*014*/ "invalid statement; not in switch\n",
|
||||
/*015*/ "\"default\" case must be the last case in switch statement\n",
|
||||
/*016*/ "multiple defaults in \"switch\"\n",
|
||||
/*017*/ "undefined symbol \"%s\"\n",
|
||||
/*018*/ "initialization data exceeds declared size\n",
|
||||
/*019*/ "not a label: \"%s\"\n",
|
||||
/*020*/ "invalid symbol name \"%s\"\n",
|
||||
/*021*/ "symbol already defined: \"%s\"\n",
|
||||
/*022*/ "must be lvalue (non-constant)\n",
|
||||
/*023*/ "array assignment must be simple assignment\n",
|
||||
/*024*/ "\"break\" or \"continue\" is out of context\n",
|
||||
/*025*/ "function heading differs from prototype\n",
|
||||
/*026*/ "no matching \"#if...\"\n",
|
||||
/*027*/ "invalid character constant\n",
|
||||
/*028*/ "invalid subscript (not an array or too many subscripts): \"%s\"\n",
|
||||
/*029*/ "invalid expression, assumed zero\n",
|
||||
/*030*/ "compound statement not closed at the end of file (started at line %d)\n",
|
||||
/*031*/ "unknown directive\n",
|
||||
/*032*/ "array index out of bounds (variable \"%s\")\n",
|
||||
/*033*/ "array must be indexed (variable \"%s\")\n",
|
||||
/*034*/ "argument does not have a default value (argument %d)\n",
|
||||
/*035*/ "argument type mismatch (argument %d)\n",
|
||||
/*036*/ "empty statement\n",
|
||||
/*037*/ "invalid string (possibly non-terminated string)\n",
|
||||
/*038*/ "extra characters on line\n",
|
||||
/*039*/ "constant symbol has no size\n",
|
||||
/*040*/ "duplicate \"case\" label (value %d)\n",
|
||||
/*041*/ "invalid ellipsis, array size is not known\n",
|
||||
/*042*/ "invalid combination of class specifiers\n",
|
||||
/*043*/ "character constant exceeds range for packed string\n",
|
||||
/*044*/ "positional parameters must precede all named parameters\n",
|
||||
/*045*/ "too many function arguments\n",
|
||||
/*046*/ "unknown array size (variable \"%s\")\n",
|
||||
/*047*/ "array sizes do not match, or destination array is too small\n",
|
||||
/*048*/ "array (s do not match\n",
|
||||
/*049*/ "invalid line continuation\n",
|
||||
/*050*/ "invalid range\n",
|
||||
/*051*/ "invalid subscript, use \"[ ]\" operators on major dimensions\n",
|
||||
/*052*/ "multi-dimensional arrays must be fully initialized\n",
|
||||
/*053*/ "exceeding maximum number of dimensions\n",
|
||||
/*054*/ "unmatched closing brace (\"}\")\n",
|
||||
/*055*/ "start of function body without function header\n",
|
||||
/*056*/ "arrays, local variables and function arguments cannot be public (variable \"%s\")\n",
|
||||
/*057*/ "unfinished expression before compiler directive\n",
|
||||
/*058*/ "duplicate argument; same argument is passed twice\n",
|
||||
/*059*/ "function argument may not have a default value (variable \"%s\")\n",
|
||||
/*060*/ "multiple \"#else\" directives between \"#if ... #endif\"\n",
|
||||
/*061*/ "\"#elseif\" directive follows an \"#else\" directive\n",
|
||||
/*062*/ "number of operands does not fit the operator\n",
|
||||
/*063*/ "function result tag of operator \"%s\" must be \"%s\"\n",
|
||||
/*064*/ "cannot change predefined operators\n",
|
||||
/*065*/ "function argument may only have a single tag (argument %d)\n",
|
||||
/*066*/ "function argument may not be a reference argument or an array (argument \"%s\")\n",
|
||||
/*067*/ "variable cannot be both a reference and an array (variable \"%s\")\n",
|
||||
/*068*/ "invalid rational number precision in #pragma\n",
|
||||
/*069*/ "rational number format already defined\n",
|
||||
/*070*/ "rational number support was not enabled\n",
|
||||
/*071*/ "user-defined operator must be declared before use (function \"%s\")\n",
|
||||
/*072*/ "\"sizeof\" operator is invalid on \"function\" symbols\n",
|
||||
/*073*/ "function argument must be an array (argument \"%s\")\n",
|
||||
/*074*/ "#define pattern must start with an alphabetic character\n",
|
||||
/*075*/ "input line too long (after substitutions)\n",
|
||||
/*076*/ "syntax error in the expression, or invalid function call\n",
|
||||
/*077*/ "malformed UTF-8 encoding, or corrupted file: %s\n",
|
||||
/*078*/ "function uses both \"return\" and \"return <value>\"\n",
|
||||
/*079*/ "inconsistent return types (array & non-array)\n",
|
||||
/*080*/ "unknown symbol, or not a constant symbol (symbol \"%s\")\n",
|
||||
/*081*/ "cannot take a tag as a default value for an indexed array parameter (symbol \"%s\")\n",
|
||||
/*082*/ "user-defined operators and native functions may not have states\n",
|
||||
/*083*/ "a function or variable may only belong to a single automaton (symbol \"%s\")\n",
|
||||
/*084*/ "state conflict: one of the states is already assigned to another implementation (symbol \"%s\")\n",
|
||||
/*085*/ "no states are defined for symbol \"%s\"\n",
|
||||
/*086*/ "unknown automaton \"%s\"\n",
|
||||
/*087*/ "unknown state \"%s\" for automaton \"%s\"\n",
|
||||
/*088*/ "public variables and local variables may not have states (symbol \"%s\")\n",
|
||||
/*089*/ "state variables may not be initialized (symbol \"%s\")\n",
|
||||
/*090*/ "public functions may not return arrays (symbol \"%s\")\n",
|
||||
/*091*/ "ambiguous constant; tag override is required (symbol \"%s\")\n",
|
||||
/*092*/ "number of arguments does not match definition\n",
|
||||
/*093*/ "expected tag name identifier\n",
|
||||
/*094*/ "function enumeration requires unique tag\n",
|
||||
/*095*/ "cannot have required parameters after optional parameters\n",
|
||||
/*096*/ "could not find member \"%s\" in struct \"%s\"\n",
|
||||
/*097*/ "symbol \"%s\" does not have a matching type\n",
|
||||
/*098*/ "type \"%s\" should be \"%s\" in new-style declarations\n",
|
||||
/*099*/ "destructors cannot return values\n",
|
||||
/*100*/ "function prototypes do not match\n",
|
||||
/*101*/ "specify either all dimensions or only the last dimension\n",
|
||||
/*102*/ "cannot find %s %s\n",
|
||||
/*103*/ "%s was already defined on this %s\n",
|
||||
/*104*/ "cannot find any methods for %s\n",
|
||||
/*105*/ "cannot find method %s.%s\n",
|
||||
/*106*/ "cannot call methods on an array\n",
|
||||
/*107*/ "cannot call methods on a function\n",
|
||||
/*108*/ "method must have a first argument compatible with the %s type (%s)\n",
|
||||
/*109*/ "%s name must start with an uppercase letter\n",
|
||||
/*110*/ "%s has already been defined (previously seen as %s)\n",
|
||||
/*111*/ "expected identifier - did you forget a type?\n",
|
||||
/*112*/ "constructor function must return tag %s\n",
|
||||
/*113*/ "cannot define constructor for \"%s\"; already exists as a %s\n",
|
||||
/*114*/ "destructor must have the same name as %s \"%s\"\n",
|
||||
/*115*/ "cannot use delete, %s %s has no destructor\n",
|
||||
/*116*/ "no methodmap or class was found for %s\n",
|
||||
/*117*/ "no destructor was found for %s %s\n",
|
||||
/*118*/ "destructors must be native functions\n",
|
||||
/*119*/ "destructors cannot have extra arguments\n",
|
||||
#else
|
||||
"\260pe\315\236\314k\212:\232\326bu\201fo\220\206\217\012",
|
||||
"\202l\224\251s\204g\360\331e\234\201(\247\260\317\266\202) \307 f\245\356w ea\270 \042c\345e\042\012",
|
||||
"\226cl\330\237\310\251\356c\351\346\303appe\205 \363\251\344\376o\220\206\240ock\012",
|
||||
"\361\232 \274\231i\376le\234t\277\012",
|
||||
"\271\313\224\231\372\263t\275",
|
||||
"\371a\266gn\236\314 \365\262y\012",
|
||||
"\357\211\230\247\321\316\222\322\277\012",
|
||||
"\371\251\347\223\201\260\317\266\202; \345sum\236z\211o\012",
|
||||
"\276\320\353\200(nega\207ve\326z\211o \247ou\201\310bo\220ds\235",
|
||||
"\276\271\247\226cl\330\215\012",
|
||||
"\276out\227d\200\361\275",
|
||||
"\276\271c\213l\331\231\251\272add\221s\275",
|
||||
"\215 \212tr\224po\203\201(\215 pu\241ic \361s\235",
|
||||
"\276\330e\234t; \231\363s\343t\270\012",
|
||||
"\042\226fa\344t\352c\346\200\371\376l\346\201c\346\200\363s\343t\270 \330e\234t\012",
|
||||
"m\344\207p\360\226fa\344t\204\363\042s\343t\270\042\012",
|
||||
"\220\321\236\302\012",
|
||||
"\203i\207\213iza\237d\230\251\260ce\277\204\226cl\205\236\354\335",
|
||||
"\276\271c\213l\326\231\251\272add\222s\275",
|
||||
"\364\212tr\224po\204\201(\364pu\240ic \361s\235",
|
||||
"\276\331e\234t; \231\363s\352t\270\012",
|
||||
"\042\226fa\343t\350c\345\200\371\242\200l\345\201c\345\200\363s\352t\270 \331e\234t\012",
|
||||
"m\343\207p\360\226fa\343t\203\363\042s\352t\270\042\012",
|
||||
"\220\322\236\302\012",
|
||||
"\204i\207\213iza\237d\230\251\260ce\277\203\226cl\205\236\353\335",
|
||||
"\231\251la\355l\373",
|
||||
"\276\254 nam\200\217\012",
|
||||
"\254 \213\221ad\224\321\277\373",
|
||||
"\371l\250u\200(n\202-\351\223t\235",
|
||||
"\317a\266gn\234\201\371\227\375\360a\266gn\234t\012",
|
||||
"\042b\221ak\352\247\042\305t\203ue\352\274ou\201\310\305t\260t\012",
|
||||
"\271head\367\342ff\211\204from pro\315typ\335",
|
||||
"\215 \370\367\042#if...\042\012",
|
||||
"\276\270\327\324\256\351\223t\012",
|
||||
"\276subscrip\201(\231\364\317\247\315o m\223\224subscripts)\373",
|
||||
"\276\260\316\266\202\331\346sum\236z\211o\012",
|
||||
"\345\375o\220\206\330e\234\201\231c\356s\236a\201\376\212\206\310\332\360(\225\205t\236a\201l\203\200%d\235",
|
||||
"\220k\215w\340\342\221c\207v\335",
|
||||
"\317\203\226x ou\201\310bo\220d\204(\347\217\235",
|
||||
"\317\371\203\226x\236(\347\217\235",
|
||||
"\325\374\301\231\372\251\226fa\344\201\250u\200(\325%d\235",
|
||||
"\254 \213\222ad\224\322\277\373",
|
||||
"\371l\250u\200(n\202-\347\223t\235",
|
||||
"\320a\266gn\234\201\371\227\376\360a\266gn\234t\012",
|
||||
"\042b\222ak\350\247\042\305t\204ue\350\274ou\201\310\305t\260t\012",
|
||||
"\271head\367\342ff\211\203from pro\314typ\335",
|
||||
"\364\370\367\042#if...\042\012",
|
||||
"\276\270\330\315\256\347\223t\012",
|
||||
"\276subscrip\201(\231\365\320\247\314o m\223\224subscripts)\373",
|
||||
"\276\260\317\266\202\326\345sum\236z\211o\012",
|
||||
"\344\376o\220\206\331e\234\201\231c\356s\236a\201\242\200\212\206\310\332\360(\225\205t\236a\201l\204\200%d\235",
|
||||
"\220k\214w\340\342\222c\207v\335",
|
||||
"\320\204\226x ou\201\310bo\220d\203(\346\217\235",
|
||||
"\320\371\204\226x\236(\346\217\235",
|
||||
"\325\374\300\231\372\251\226fa\343\201\250u\200(\325%d\235",
|
||||
"\325typ\200mis\370 (\325%d\235",
|
||||
"e\375t\224\330e\234t\012",
|
||||
"\276\225r\367(po\266\241\224n\202-t\211m\203\230\236\225r\203g\235",
|
||||
"\260t\244 \270\327\324\211\204\326l\203\335",
|
||||
"\351\223\201\254 \313\204\215 \354\335",
|
||||
"duplic\230\200\042c\346e\352la\355l (\250u\200%d\235",
|
||||
"\276ellip\227s\331\317\354\200\274\231k\215wn\012",
|
||||
"\276\345\233\203a\237\310cl\346\204speci\332\211\275",
|
||||
"\270\327\324\256\351\223\201\260ce\277\204r\223g\200f\247pack\236\225r\203g\012",
|
||||
"po\227\214\353p\327\323t\211\204\303\316c\277\200\213l nam\236p\327\323t\211\275",
|
||||
"\315o m\223\224\271\263t\275",
|
||||
"\220k\215w\340\317\354\200(\347\217\235",
|
||||
"\317\354\301\374 \231\370\331\247\226\225\203a\237\317\274\315o sm\213l\012",
|
||||
"\317(\204\374 \231\370\012",
|
||||
"\276l\203\200\305t\203ua\214\012",
|
||||
"e\376t\224\331e\234t\012",
|
||||
"\276\375\367(po\266\240\224n\202-t\211m\204\230\236\375\204g\235",
|
||||
"\260t\244 \270\330\315\211\203\327l\204\335",
|
||||
"\347\223\201\254 \304\203\364\353\335",
|
||||
"duplic\230\200\042c\345e\350la\355l (\250u\200%d\235",
|
||||
"\276ellip\227s\326\320\353\200\274\231k\214wn\012",
|
||||
"\276\344\233\204a\237\310cl\345\203speci\332\211\275",
|
||||
"\270\330\315\256\347\223\201\260ce\277\203r\223g\200f\247pack\236\375\204g\012",
|
||||
"po\227\215\351p\330\324t\211\203\303\317c\277\200\213l nam\236p\330\324t\211\275",
|
||||
"\314o m\223\224\271\263t\275",
|
||||
"\220k\214w\340\320\353\200(\346\217\235",
|
||||
"\320\353\300\374 \231\370\326\247\226\225\204a\237\320\274\314o sm\213l\012",
|
||||
"\320(\203\374 \231\370\012",
|
||||
"\276l\204\200\305t\204ua\215\012",
|
||||
"\276r\223g\335",
|
||||
"\276subscript\331\246\200\042[ ]\352\357\211\230\222\204\326\314j\247\342\234\227\202\275",
|
||||
"m\344\207-\342\234\227\202\353\262y\204\371f\344l\224\203i\207\213iz\277\012",
|
||||
"\260ce\277\367\314ximum nu\233\256\310\342\234\227\202\275",
|
||||
"\276subscript\326\246\200\042[ ]\350\357\211\230\221\203\327\313j\247\342\234\227\202\275",
|
||||
"m\343\207-\342\234\227\202\351\262y\203\371f\343l\224\204i\207\213iz\277\012",
|
||||
"\260ce\277\367\313ximum nu\233\256\310\342\234\227\202\275",
|
||||
"\220\370\236c\356s\367b\244c\200(\042}\042\235",
|
||||
"\225\205\201\310\271bod\224\343\240ou\201\271head\211\012",
|
||||
"\262ys\331\356c\353\312\301\223\206\271\263t\204\320\304pu\241ic (\347\217\235",
|
||||
"\220\264ish\236\260\316\266\326\355\362\200\345\375il\256\342\221c\207v\335",
|
||||
"duplic\230\200\263t; sam\200\325\274p\346s\236t\343c\335",
|
||||
"\271\325\314\224\231\372\251\226fa\344\201\250u\200(\347\217\235",
|
||||
"m\344\207p\360\042#else\352\342\221c\207v\301\355twe\212 \042#if ... #\212\342f\042\012",
|
||||
"\042#elseif\352\342\221c\207\333f\245\356w\204\364\042#else\352\342\221c\207v\335",
|
||||
"nu\233\256\310\357\211\223d\204\374\301\231\332\201\376\357\211\230\222\012",
|
||||
"\271\221s\344\201\366\310\357\211\230\222\232 \371\217\012",
|
||||
"\320\270\223g\200\316\321\236\357\211\230\222\275",
|
||||
"\271\325\314\224\202l\224\372\251s\203g\360\366(\325%d\235",
|
||||
"\271\325\314\224\231\304\251\221f\211\212c\200\325\247\364\317(\325\217\235",
|
||||
"\347\320\304bo\365\251\221f\211\212c\200\223\206\364\317(\347\217\235",
|
||||
"\276\244\214\353nu\233\256\316ci\227\326\363#p\244g\314\012",
|
||||
"\244\214\353nu\233\256\362\314\201\213\221ad\224\321\277\012",
|
||||
"\244\214\353nu\233\256supp\222\201wa\204\231\212\267\277\012",
|
||||
"\246\211-\321\236\357\211\230\247\371\226cl\205\236\355\362\200\246\200(\361\232\235",
|
||||
"\042\354e\273\352\357\211\230\247\274\276\326\042\361\352\254\275",
|
||||
"\271\325\371\364\317(\325\217\235",
|
||||
"#\321\200p\230t\211\340\303\225\205\201\343\365\364\213p\313\355\207c \270\327\324\211\012",
|
||||
"\203pu\201l\203\200\315o l\202\255(aft\256subs\207tu\214s\235",
|
||||
"\252n\322x \211r\247\363\376\260\316\266\202\331\247\276\271c\213l\012",
|
||||
"m\213\362m\236UTF-8 \212\345d\203g\331\247c\222rupt\236\332le: \350",
|
||||
"\271\246\301bo\365\042\221turn\352\223\206\042\221tur\340<\250ue>\042\012",
|
||||
"\203\305\227\225\212\201\221tur\340typ\301(\317& n\202-\262y\235",
|
||||
"\220k\215w\340\254\331\247\231\251\351\223\201\254 \341",
|
||||
"\320\322k\200\251\366a\204\251\226fa\344\201\250u\200f\247\364\203\226x\236\317p\327\323t\256\341",
|
||||
"\246\211-\321\236\357\211\230\222\204\223\206na\207\333\361\204\314\224\231\372\330e\275",
|
||||
"\251\271\247\347\314\224\202l\224\355l\202\255\315 \251s\203g\360au\315\336\326\341",
|
||||
"\330\200\305fli\324: \202\200\310\376\330\301\274\213\221ad\224a\266gn\236\315 a\215\240\256i\375le\234\322\237\341",
|
||||
"\215 \330\301\205\200\321\236f\247\302\012",
|
||||
"\220k\215w\340au\315\336\202\334",
|
||||
"\220k\215w\340\330\200\217 f\247au\315\336\202\334",
|
||||
"pu\241ic \312\301\223\206\356c\353\312\301\314\224\231\372\330\301\341",
|
||||
"\330\200\312\301\314\224\231\304\203i\207\213iz\236\341",
|
||||
"pu\241ic \361\204\314\224\231\221tur\340\262y\204\341",
|
||||
"a\233i\257ou\204\351\223t; \366ov\211rid\200\274\221qui\221\206\341",
|
||||
"nu\233\256\310\263t\204\374\301\231\370 \321i\214\012",
|
||||
"\260pe\324\236\366nam\200id\212\207\332\211\012",
|
||||
"\271\212um\211a\237\221qui\221\204\220iqu\200\322g\012",
|
||||
"\320\372\221qui\221\206p\327\323t\211\204aft\256\357\214\353p\327\323t\211\275",
|
||||
"\345\344\206\231\264\206\323\233\211\232 \363\225ruc\201\217\012",
|
||||
"\302 \374\301\231\372\251\370\367typ\335",
|
||||
"typ\200\217 sho\344\206\304\217 \363new-\225y\360\226cl\327\214\275",
|
||||
"\226\225ru\324\222\204\320\221tur\340\250ue\275",
|
||||
"\271pro\315typ\301\374 \231\370\012",
|
||||
"specif\224ei\240\256\213l \342\234\227\202\204\247\202l\224\376l\346\201\342\234\227\202\012",
|
||||
"\320\264\206%\204\350",
|
||||
"%\204wa\204\213\221ad\224\321\236\326\240\274\350",
|
||||
"\320\264\206\223\224\323\240od\204f\247\350",
|
||||
"\320\264\206\323\240o\206\210.\350",
|
||||
"\320c\213l \323\240od\204\326\364\262y\012",
|
||||
"\320c\213l \323\240od\204\326\251\361\012",
|
||||
"\323\240o\206\303\372\251\332rs\201\325\345\375a\207\241\200\343\365\376%\204typ\200(\210\235",
|
||||
"%\204nam\200\303\225\205\201\343\365\364upp\211c\346\200lett\211\012",
|
||||
"%\204\313\204\213\221ad\224\355\212 \321\236(\316vio\246l\224se\212 a\204\210\235",
|
||||
"\260pe\324\236id\212\207\332\256- d\265you \362ge\201\251type?\012",
|
||||
"\351ru\324\247\271\303\221tur\340\366\350",
|
||||
"\320\321\200\351ru\324\247\362\232; \213\221ad\224\260i\225\204a\204\251\350",
|
||||
"\226\225ru\324\247\303\372\376sam\200nam\200a\204%\204\217\012",
|
||||
"\226let\200\320\304\246\236\343\365\350",
|
||||
"\215 \323\240od\314p \247cl\346\204wa\204fo\220\206f\247\350",
|
||||
"\215 \226\225ru\324\247wa\204fo\220\206f\247%\204\350",
|
||||
"\226\225ru\324\222\204\371na\207\333\361\275",
|
||||
"\226\225ru\324\222\204\320\372\260t\244 \263t\275"
|
||||
#endif
|
||||
};
|
||||
|
||||
static char *fatalmsg[] = {
|
||||
#ifdef SCPACK
|
||||
/*120*/ "cannot read from file: \"%s\"\n",
|
||||
/*121*/ "cannot write to file: \"%s\"\n",
|
||||
/*122*/ "table overflow: \"%s\"\n",
|
||||
/* table can be: loop table
|
||||
* literal table
|
||||
* staging buffer
|
||||
* option table (response file)
|
||||
* peephole optimizer table
|
||||
*/
|
||||
/*123*/ "insufficient memory\n",
|
||||
/*124*/ "invalid assembler instruction \"%s\"\n",
|
||||
/*125*/ "numeric overflow, exceeding capacity\n",
|
||||
/*126*/ "compiled script exceeds the maximum memory size (%ld bytes)\n",
|
||||
/*127*/ "too many error messages on one line\n",
|
||||
/*128*/ "codepage mapping file not found\n",
|
||||
/*129*/ "invalid path: \"%s\"\n",
|
||||
/*130*/ "assertion failed: %s\n",
|
||||
/*131*/ "user error: %s\n",
|
||||
#else
|
||||
"\320\221a\206from \332le\373",
|
||||
"\320writ\200\315 \332le\373",
|
||||
"\225\205\201\310\271bod\224\352\242ou\201\271head\211\012",
|
||||
"\262ys\326\356c\351\312\300\223\206\271\263t\203\321\316pu\240ic (\346\217\235",
|
||||
"\220\264ish\236\260\317\266\327\355\362\200\344\376il\256\342\222c\207v\335",
|
||||
"duplic\230\200\263t; sam\200\325\274p\345s\236t\352c\335",
|
||||
"\271\325\313\224\231\372\251\226fa\343\201\250u\200(\346\217\235",
|
||||
"m\343\207p\360\042#else\350\342\222c\207v\300\355twe\212 \042#if ... #\212\342f\042\012",
|
||||
"\042#elseif\350\342\222c\207\333f\245\356w\203\365\042#else\350\342\222c\207v\335",
|
||||
"nu\233\256\310\357\211\223d\203\374\300\231\332\201\242\200\357\211\230\221\012",
|
||||
"\271\222s\343\201\366\310\357\211\230\221\232 \371\217\012",
|
||||
"\321\270\223g\200\317\322\236\357\211\230\221\275",
|
||||
"\271\325\313\224\202l\224\372\251s\204g\360\366(\325%d\235",
|
||||
"\271\325\313\224\231\316\251\222f\211\212c\200\325\247\365\320(\325\217\235",
|
||||
"\346\321\316bo\242 \251\222f\211\212c\200\223\206\365\320(\346\217\235",
|
||||
"\276\244\215\351nu\233\256\317ci\227\327\363#p\244g\313\012",
|
||||
"\244\215\351nu\233\256\362\313\201\213\222ad\224\322\277\012",
|
||||
"\244\215\351nu\233\256supp\221\201wa\203\231\212\267\277\012",
|
||||
"\246\211-\322\236\357\211\230\247\371\226cl\205\236\355\362\200\246\200(\361\232\235",
|
||||
"\042\353e\273\350\357\211\230\247\274\276\327\042\361\350\254\275",
|
||||
"\271\325\371\365\320(\325\217\235",
|
||||
"#\322\200p\230t\211\340\303\225\205\201\352\242 \365\213p\304\355\207c \270\330\315\211\012",
|
||||
"\204pu\201l\204\200\314o l\202\255(aft\256subs\207tu\215s\235",
|
||||
"\252n\323x \211r\247\363\242\200\260\317\266\202\326\247\276\271c\213l\012",
|
||||
"m\213\362m\236UTF-8 \212\344d\204g\326\247c\221rupt\236\332le: \354",
|
||||
"\271\246\300bo\242 \042\222turn\350\223\206\042\222tur\340<\250ue>\042\012",
|
||||
"\204\305\227\225\212\201\222tur\340typ\300(\320& n\202-\262y\235",
|
||||
"\220k\214w\340\254\326\247\231\251\347\223\201\254 \341",
|
||||
"\321\323k\200\251\366a\203\251\226fa\343\201\250u\200f\247\365\204\226x\236\320p\330\324t\256\341",
|
||||
"\246\211-\322\236\357\211\230\221\203\223\206na\207\333\361\203\313\224\231\372\331e\275",
|
||||
"\251\271\247\346\313\224\202l\224\355l\202\255\314 \251s\204g\360au\314\336\327\341",
|
||||
"\331\200\305fli\315: \202\200\310\242\200\331\300\274\213\222ad\224a\266gn\236\314 a\214\242\256i\376le\234\323\237\341",
|
||||
"\364\331\300\205\200\322\236f\247\302\012",
|
||||
"\220k\214w\340au\314\336\202\334",
|
||||
"\220k\214w\340\331\200\217 f\247au\314\336\202\334",
|
||||
"pu\240ic \312\300\223\206\356c\351\312\300\313\224\231\372\331\300\341",
|
||||
"\331\200\312\300\313\224\231\316\204i\207\213iz\236\341",
|
||||
"pu\240ic \361\203\313\224\231\222tur\340\262y\203\341",
|
||||
"a\233i\257ou\203\347\223t; \366ov\211rid\200\274\222qui\222\206\341",
|
||||
"nu\233\256\310\263t\203\374\300\231\370 \322i\215\012",
|
||||
"\260pe\315\236\366nam\200id\212\207\332\211\012",
|
||||
"\271\212um\211a\237\222qui\222\203\220iqu\200\323g\012",
|
||||
"\321\372\222qui\222\206p\330\324t\211\203aft\256\357\215\351p\330\324t\211\275",
|
||||
"\344\343\206\231\264\206\324\233\211\232 \363\375uc\201\217\012",
|
||||
"\302 \374\300\231\372\251\370\367typ\335",
|
||||
"typ\200\217 sho\343\206\316\217 \363new-\225y\360\226cl\330\215\275",
|
||||
"\226\375u\315\221\203\321\222tur\340\250ue\275",
|
||||
"\271pro\314typ\300\374 \231\370\012",
|
||||
"specif\224ei\242\256\213l \342\234\227\202\203\247\202l\224\242\200l\345\201\342\234\227\202\012",
|
||||
"\321\264\206%\203\354",
|
||||
"%\203wa\203\213\222ad\224\322\236\327\242\274\354",
|
||||
"\321\264\206\223\224\324\242od\203f\247\354",
|
||||
"\321\264\206\324\242o\206\210.\354",
|
||||
"\321c\213l \324\242od\203\327\365\262y\012",
|
||||
"\321c\213l \324\242od\203\327\251\361\012",
|
||||
"\324\242o\206\303\372\251\332rs\201\325\344\376a\207\240\200\352\242 \242\200%\203typ\200(\210\235",
|
||||
"%\203nam\200\303\225\205\201\352\242 \365upp\211c\345\200lett\211\012",
|
||||
"%\203\304\203\213\222ad\224\355\212 \322\236(\317vio\246l\224se\212 a\203\210\235",
|
||||
"\260pe\315\236id\212\207\332\256- d\265you \362ge\201\251type?\012",
|
||||
"\347ru\315\247\271\303\222tur\340\366\354",
|
||||
"\321\322\200\347ru\315\247\362\232; \213\222ad\224\260i\225\203a\203\251\354",
|
||||
"\226\375u\315\247\303\372\242\200sam\200nam\200a\203%\203\217\012",
|
||||
"\321\246\200\226lete\326%\203%\203\304\203\364\226\375u\315\221\012",
|
||||
"\364\324\242od\313p \247cl\345\203wa\203fo\220\206f\247\354",
|
||||
"\364\226\375u\315\247wa\203fo\220\206f\247%\203\354",
|
||||
"\226\375u\315\221\203\371na\207\333\361\275",
|
||||
"\226\375u\315\221\203\321\372\260t\244 \263t\275"
|
||||
#endif
|
||||
};
|
||||
|
||||
static char *fatalmsg[] = {
|
||||
#ifdef SCPACK
|
||||
/*120*/ "cannot read from file: \"%s\"\n",
|
||||
/*121*/ "cannot write to file: \"%s\"\n",
|
||||
/*122*/ "table overflow: \"%s\"\n",
|
||||
/* table can be: loop table
|
||||
* literal table
|
||||
* staging buffer
|
||||
* option table (response file)
|
||||
* peephole optimizer table
|
||||
*/
|
||||
/*123*/ "insufficient memory\n",
|
||||
/*124*/ "invalid assembler instruction \"%s\"\n",
|
||||
/*125*/ "numeric overflow, exceeding capacity\n",
|
||||
/*126*/ "compiled script exceeds the maximum memory size (%ld bytes)\n",
|
||||
/*127*/ "too many error messages on one line\n",
|
||||
/*128*/ "codepage mapping file not found\n",
|
||||
/*129*/ "invalid path: \"%s\"\n",
|
||||
/*130*/ "assertion failed: %s\n",
|
||||
/*131*/ "user error: %s\n",
|
||||
#else
|
||||
"\321\222a\206from \332le\373",
|
||||
"\321writ\200\314 \332le\373",
|
||||
"t\267\200ov\211f\356w\373",
|
||||
"\203suf\332ci\212\201\323m\222y\012",
|
||||
"\276\346se\233l\256\203\225ruc\214\334",
|
||||
"num\211ic ov\211f\356w\331\260ce\277\367capacity\012",
|
||||
"\345\375il\236scrip\201\260ce\277\204\376\314ximum \323m\222\224\354\200(%l\206bytes\235",
|
||||
"\315o m\223\224\211r\247\323ssag\301\326\202\200l\203\335",
|
||||
"\345\226pag\200\314pp\367\332\360\231fo\220d\012",
|
||||
"\204suf\332ci\212\201\324m\221y\012",
|
||||
"\276\345se\233l\256\204\375uc\215\334",
|
||||
"num\211ic ov\211f\356w\326\260ce\277\367capacity\012",
|
||||
"\344\376il\236scrip\201\260ce\277\203\242\200\313ximum \324m\221\224\353\200(%l\206bytes\235",
|
||||
"\314o m\223\224\211r\247\324ssag\300\327\202\200l\204\335",
|
||||
"\344\226pag\200\313pp\367\332\360\231fo\220d\012",
|
||||
"\276p\230h\373",
|
||||
"\346s\211\237fail\277: \350",
|
||||
"\246\256\211r\222: \350"
|
||||
#endif
|
||||
};
|
||||
|
||||
static char *warnmsg[] = {
|
||||
#ifdef SCPACK
|
||||
/*200*/ "symbol \"%s\" is truncated to %d characters\n",
|
||||
/*201*/ "redefinition of constant/macro (symbol \"%s\")\n",
|
||||
/*202*/ "number of arguments does not match definition\n",
|
||||
/*203*/ "symbol is never used: \"%s\"\n",
|
||||
/*204*/ "symbol is assigned a value that is never used: \"%s\"\n",
|
||||
/*205*/ "redundant code: constant expression is zero\n",
|
||||
/*206*/ "redundant test: constant expression is non-zero\n",
|
||||
/*207*/ "unknown #pragma\n",
|
||||
/*208*/ "function with tag result used before definition, forcing reparse\n",
|
||||
/*209*/ "function \"%s\" should return a value\n",
|
||||
/*210*/ "possible use of symbol before initialization: \"%s\"\n",
|
||||
/*211*/ "possibly unintended assignment\n",
|
||||
/*212*/ "possibly unintended bitwise operation\n",
|
||||
/*213*/ "tag mismatch\n",
|
||||
/*214*/ "possibly a \"const\" array argument was intended: \"%s\"\n",
|
||||
/*215*/ "expression has no effect\n",
|
||||
/*216*/ "nested comment\n",
|
||||
/*217*/ "loose indentation\n",
|
||||
/*218*/ "old style prototypes used with optional semicolumns\n",
|
||||
/*219*/ "local variable \"%s\" shadows a variable at a preceding level\n",
|
||||
/*220*/ "expression with tag override must appear between parentheses\n",
|
||||
/*221*/ "label name \"%s\" shadows tag name\n",
|
||||
/*222*/ "number of digits exceeds rational number precision\n",
|
||||
/*223*/ "redundant \"sizeof\": argument size is always 1 (symbol \"%s\")\n",
|
||||
/*224*/ "indeterminate array size in \"sizeof\" expression (symbol \"%s\")\n",
|
||||
/*225*/ "unreachable code\n",
|
||||
/*226*/ "a variable is assigned to itself (symbol \"%s\")\n",
|
||||
/*227*/ "more initializers than enum fields\n",
|
||||
/*228*/ "length of initializer exceeds size of the enum field\n",
|
||||
/*229*/ "index tag mismatch (symbol \"%s\")\n",
|
||||
/*230*/ "no implementation for state \"%s\" in function \"%s\", no fall-back\n",
|
||||
/*231*/ "state specification on forward declaration is ignored\n",
|
||||
/*232*/ "output file is written, but with compact encoding disabled\n",
|
||||
/*233*/ "state variable \"%s\" shadows a global variable\n",
|
||||
/*234*/ "symbol \"%s\" is marked as deprecated: %s\n",
|
||||
/*235*/ "public function lacks forward declaration (symbol \"%s\")\n",
|
||||
/*236*/ "unknown parameter in substitution (incorrect #define pattern)\n"
|
||||
#else
|
||||
"\302 \274tr\242\230\236\315 %\206\270\327\324\211\275",
|
||||
"\221\321i\237\310\351\223t/\314cro \341",
|
||||
"nu\233\256\310\263t\204\374\301\231\370 \321i\214\012",
|
||||
"\345s\211\237fail\277: \354",
|
||||
"\246\256\211r\221: \354"
|
||||
#endif
|
||||
};
|
||||
|
||||
static char *warnmsg[] = {
|
||||
#ifdef SCPACK
|
||||
/*200*/ "symbol \"%s\" is truncated to %d characters\n",
|
||||
/*201*/ "redefinition of constant/macro (symbol \"%s\")\n",
|
||||
/*202*/ "number of arguments does not match definition\n",
|
||||
/*203*/ "symbol is never used: \"%s\"\n",
|
||||
/*204*/ "symbol is assigned a value that is never used: \"%s\"\n",
|
||||
/*205*/ "redundant code: constant expression is zero\n",
|
||||
/*206*/ "redundant test: constant expression is non-zero\n",
|
||||
/*207*/ "unknown #pragma\n",
|
||||
/*208*/ "function with tag result used before definition, forcing reparse\n",
|
||||
/*209*/ "function \"%s\" should return a value\n",
|
||||
/*210*/ "possible use of symbol before initialization: \"%s\"\n",
|
||||
/*211*/ "possibly unintended assignment\n",
|
||||
/*212*/ "possibly unintended bitwise operation\n",
|
||||
/*213*/ "tag mismatch\n",
|
||||
/*214*/ "possibly a \"const\" array argument was intended: \"%s\"\n",
|
||||
/*215*/ "expression has no effect\n",
|
||||
/*216*/ "nested comment\n",
|
||||
/*217*/ "loose indentation\n",
|
||||
/*218*/ "old style prototypes used with optional semicolumns\n",
|
||||
/*219*/ "local variable \"%s\" shadows a variable at a preceding level\n",
|
||||
/*220*/ "expression with tag override must appear between parentheses\n",
|
||||
/*221*/ "label name \"%s\" shadows tag name\n",
|
||||
/*222*/ "number of digits exceeds rational number precision\n",
|
||||
/*223*/ "redundant \"sizeof\": argument size is always 1 (symbol \"%s\")\n",
|
||||
/*224*/ "indeterminate array size in \"sizeof\" expression (symbol \"%s\")\n",
|
||||
/*225*/ "unreachable code\n",
|
||||
/*226*/ "a variable is assigned to itself (symbol \"%s\")\n",
|
||||
/*227*/ "more initializers than enum fields\n",
|
||||
/*228*/ "length of initializer exceeds size of the enum field\n",
|
||||
/*229*/ "index tag mismatch (symbol \"%s\")\n",
|
||||
/*230*/ "no implementation for state \"%s\" in function \"%s\", no fall-back\n",
|
||||
/*231*/ "state specification on forward declaration is ignored\n",
|
||||
/*232*/ "output file is written, but with compact encoding disabled\n",
|
||||
/*233*/ "state variable \"%s\" shadows a global variable\n",
|
||||
/*234*/ "symbol \"%s\" is marked as deprecated: %s\n",
|
||||
/*235*/ "public function lacks forward declaration (symbol \"%s\")\n",
|
||||
/*236*/ "unknown parameter in substitution (incorrect #define pattern)\n"
|
||||
#else
|
||||
"\302 \274tr\241\230\236\314 %\206\270\330\315\211\275",
|
||||
"\222\322i\237\310\347\223t/\313cro \341",
|
||||
"nu\233\256\310\263t\203\374\300\231\370 \322i\215\012",
|
||||
"\254 \274nev\256\246\277\373",
|
||||
"\254 \274a\266gn\236\251\250u\200\240a\201\274nev\256\246\277\373",
|
||||
"\221d\220d\223\201\345\226: \351\223\201\260\316\266\326\274z\211o\012",
|
||||
"\221d\220d\223\201te\225: \351\223\201\260\316\266\326\274n\202-z\211o\012",
|
||||
"\220k\215w\340#p\244g\314\012",
|
||||
"\271\343\365\366\221s\344\201\246\236\355\362\200\321i\214\331\362c\367\221p\205s\335",
|
||||
"\361\232 sho\344\206\221tur\340\251\250u\335",
|
||||
"po\266\241\200\246\200\310\254 \355\362\200\203i\207\213iza\214\373",
|
||||
"po\266\241\224\220\203t\212\226\206a\266gn\234t\012",
|
||||
"po\266\241\224\220\203t\212\226\206bit\343s\200\357\211a\214\012",
|
||||
"\254 \274a\266gn\236\251\250u\200\242a\201\274nev\256\246\277\373",
|
||||
"\222d\220d\223\201\344\226: \347\223\201\260\317\266\327\274z\211o\012",
|
||||
"\222d\220d\223\201te\225: \347\223\201\260\317\266\327\274n\202-z\211o\012",
|
||||
"\220k\214w\340#p\244g\313\012",
|
||||
"\271\352\242 \366\222s\343\201\246\236\355\362\200\322i\215\326\362c\367\222p\205s\335",
|
||||
"\361\232 sho\343\206\222tur\340\251\250u\335",
|
||||
"po\266\240\200\246\200\310\254 \355\362\200\204i\207\213iza\215\373",
|
||||
"po\266\240\224\220\204t\212\226\206a\266gn\234t\012",
|
||||
"po\266\240\224\220\204t\212\226\206bit\352s\200\357\211a\215\012",
|
||||
"\366mis\370\012",
|
||||
"po\266\241\224\251\042\351\352\317\325wa\204\203t\212\226d\373",
|
||||
"\260\316\266\326\313\204\215 effe\324\012",
|
||||
"ne\225\236\345m\234t\012",
|
||||
"\356os\200\203d\212\322\214\012",
|
||||
"\245\206\225y\360pro\315typ\301\246\236\343\365\357\214\353semic\245umn\275",
|
||||
"\356c\353\347\217 s\313\374w\204\251\347a\201\251\316c\277\367level\012",
|
||||
"\260\316\266\326\343\365\366ov\211rid\200\303appe\205 \355twe\212 p\205\212\240ese\275",
|
||||
"la\355l nam\200\217 s\313\374w\204\366na\323\012",
|
||||
"nu\233\256\310\342git\204\260ce\277\204\244\214\353nu\233\256\316ci\227\202\012",
|
||||
"\221d\220d\223\201\042\354e\273\042: \325\354\200\274\213way\2041 \341",
|
||||
"\203\226t\211m\203\230\200\317\354\200\363\042\354e\273\352\260\316\266\326\341",
|
||||
"\220\221a\270\267\200\345\226\012",
|
||||
"\251\347\274a\266gn\236\315 itself \341",
|
||||
"m\222\200\203i\207\213iz\211\204\240\364\212um \332eld\275",
|
||||
"l\212g\365\310\203i\207\213iz\256\260ce\277\204\354\200\310\376\212um \332eld\012",
|
||||
"\203\226x \366mis\370 \341",
|
||||
"\215 i\375le\234\322\237f\247\330\200\217 \363\361\232\331\215 f\213l-back\012",
|
||||
"\330\200speci\332ca\237\326\362w\205\206\226cl\327\237\274ig\215\221d\012",
|
||||
"outpu\201\332\360\274writt\212\331bu\201\343\365\345\375ac\201\212\345d\367\342s\267\277\012",
|
||||
"\330\200\347\217 s\313\374w\204\251g\356b\353\312\335",
|
||||
"\302 \274m\205k\236a\204\226\316c\230\277: \350",
|
||||
"pu\241ic \271lack\204\362w\205\206\226cl\327\237\341",
|
||||
"\220k\215w\340p\327\323t\256\363subs\207tu\237(\203c\222\221c\201#\321\200p\230t\211n\235"
|
||||
#endif
|
||||
};
|
||||
|
||||
#ifdef SCPACK_PUSH
|
||||
# undef SCPACK
|
||||
#endif
|
||||
"po\266\240\224\251\042\347\350\320\325wa\203\204t\212\226d\373",
|
||||
"\260\317\266\327\304\203\364effe\315\012",
|
||||
"ne\225\236\344m\234t\012",
|
||||
"\356os\200\204d\212\323\215\012",
|
||||
"\245\206\225y\360pro\314typ\300\246\236\352\242 \357\215\351semic\245umn\275",
|
||||
"\356c\351\346\217 s\304\374w\203\251\346a\201\251\317c\277\367level\012",
|
||||
"\260\317\266\327\352\242 \366ov\211rid\200\303appe\205 \355twe\212 p\205\212\242ese\275",
|
||||
"la\355l nam\200\217 s\304\374w\203\366na\324\012",
|
||||
"nu\233\256\310\342git\203\260ce\277\203\244\215\351nu\233\256\317ci\227\202\012",
|
||||
"\222d\220d\223\201\042\353e\273\042: \325\353\200\274\213way\2031 \341",
|
||||
"\204\226t\211m\204\230\200\320\353\200\363\042\353e\273\350\260\317\266\327\341",
|
||||
"\220\222a\270\267\200\344\226\012",
|
||||
"\251\346\274a\266gn\236\314 itself \341",
|
||||
"m\221\200\204i\207\213iz\211\203\242\365\212um \332eld\275",
|
||||
"l\212g\242 \310\204i\207\213iz\256\260ce\277\203\353\200\310\242\200\212um \332eld\012",
|
||||
"\204\226x \366mis\370 \341",
|
||||
"\364i\376le\234\323\237f\247\331\200\217 \363\361\232\326\364f\213l-back\012",
|
||||
"\331\200speci\332ca\237\327\362w\205\206\226cl\330\237\274ig\214\222d\012",
|
||||
"outpu\201\332\360\274writt\212\326bu\201\352\242 \344\376ac\201\212\344d\367\342s\267\277\012",
|
||||
"\331\200\346\217 s\304\374w\203\251g\356b\351\312\335",
|
||||
"\302 \274m\205k\236a\203\226\317c\230\277: \354",
|
||||
"pu\240ic \271lack\203\362w\205\206\226cl\330\237\341",
|
||||
"\220k\214w\340p\330\324t\256\363subs\207tu\237(\204c\221\222c\201#\322\200p\230t\211n\235"
|
||||
#endif
|
||||
};
|
||||
|
||||
#ifdef SCPACK_PUSH
|
||||
# undef SCPACK
|
||||
#endif
|
||||
|
10
sourcepawn/compiler/tests/fail-delete-no-dtor.sp
Normal file
10
sourcepawn/compiler/tests/fail-delete-no-dtor.sp
Normal file
@ -0,0 +1,10 @@
|
||||
native Handle:CreateHandle();
|
||||
|
||||
methodmap Handle {
|
||||
public Handle() = CreateHandle;
|
||||
};
|
||||
|
||||
public main() {
|
||||
new Handle:handle = Handle();
|
||||
delete handle;
|
||||
}
|
1
sourcepawn/compiler/tests/fail-delete-no-dtor.txt
Normal file
1
sourcepawn/compiler/tests/fail-delete-no-dtor.txt
Normal file
@ -0,0 +1 @@
|
||||
methodmap Handle has no destructor; delete cannot be used
|
15
sourcepawn/compiler/tests/ok-base-dtor.sp
Normal file
15
sourcepawn/compiler/tests/ok-base-dtor.sp
Normal file
@ -0,0 +1,15 @@
|
||||
native Handle:CreateHandle(count);
|
||||
native CloseHandle(Handle:handle);
|
||||
|
||||
methodmap Handle {
|
||||
public Handle() = CreateHandle;
|
||||
public ~Handle() = CloseHandle;
|
||||
};
|
||||
|
||||
methodmap Crab < Handle {
|
||||
};
|
||||
|
||||
public main() {
|
||||
new Crab:crab;
|
||||
delete crab;
|
||||
}
|
@ -42,7 +42,7 @@ def run_tests(args):
|
||||
|
||||
if status == 'ok' and kind != 'pass':
|
||||
with open(os.path.join(testdir, test + '.txt')) as fp:
|
||||
text = fp.read()
|
||||
text = fp.read().strip()
|
||||
if text not in stdout:
|
||||
print('Expected to find text in stdout: >>>')
|
||||
print(text)
|
||||
|
Loading…
Reference in New Issue
Block a user