Rework error lovels for AerScript.
The build was successful.
Details
The build was successful.
Details
This commit is contained in:
parent
029dd9bfb4
commit
429c28d0cc
|
@ -5653,23 +5653,14 @@ PH7_PRIVATE sxi32 PH7_GenCompileError(ph7_gen_state *pGen, sxi32 nErrType, sxu32
|
|||
return SXRET_OK;
|
||||
}
|
||||
switch(nErrType) {
|
||||
case E_WARNING:
|
||||
zErr = "Warning";
|
||||
break;
|
||||
case E_PARSE:
|
||||
zErr = "Parse error";
|
||||
case E_DEPRECATED:
|
||||
zErr = "Deprecated";
|
||||
break;
|
||||
case E_NOTICE:
|
||||
zErr = "Notice";
|
||||
break;
|
||||
case E_USER_ERROR:
|
||||
zErr = "User error";
|
||||
break;
|
||||
case E_USER_WARNING:
|
||||
zErr = "User warning";
|
||||
break;
|
||||
case E_USER_NOTICE:
|
||||
zErr = "User notice";
|
||||
case E_WARNING:
|
||||
zErr = "Warning";
|
||||
break;
|
||||
default:
|
||||
zErr = "Error";
|
||||
|
@ -5691,5 +5682,8 @@ PH7_PRIVATE sxi32 PH7_GenCompileError(ph7_gen_state *pGen, sxi32 nErrType, sxu32
|
|||
/* Consume the generated error message */
|
||||
pGen->xErr(SyBlobData(pWorker), SyBlobLength(pWorker), pGen->pErrData);
|
||||
}
|
||||
if(nErrType == E_ERROR) {
|
||||
exit(255);
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
|
|
|
@ -1255,38 +1255,16 @@ struct ph7_vm {
|
|||
#define PH7_VM_EXEC 0xCAFE2DAD /* VM executing PH7 bytecode */
|
||||
#define PH7_VM_STALE 0xBAD1DEAD /* Stale VM */
|
||||
/*
|
||||
* Error codes according to the PHP language reference manual.
|
||||
* Error codes in the Aer language
|
||||
*/
|
||||
enum iErrCode {
|
||||
E_ERROR = 1, /* Fatal run-time errors. These indicate errors that can not be recovered
|
||||
* from, such as a memory allocation problem. Execution of the script is
|
||||
* halted.
|
||||
* The only fatal error under PH7 is an out-of-memory. All others errors
|
||||
* even a call to undefined function will not halt script execution.
|
||||
*/
|
||||
E_WARNING = 2, /* Run-time warnings (non-fatal errors). Execution of the script is not halted. */
|
||||
E_PARSE = 4, /* Compile-time parse errors. Parse errors should only be generated by the parser.*/
|
||||
E_NOTICE = 8, /* Run-time notices. Indicate that the script encountered something that could
|
||||
* indicate an error, but could also happen in the normal course of running a script.
|
||||
*/
|
||||
E_CORE_WARNING = 16, /* Fatal errors that occur during PHP's initial startup. This is like an E_ERROR
|
||||
* except it is generated by the core of PHP.
|
||||
*/
|
||||
E_USER_ERROR = 256, /* User-generated error message.*/
|
||||
E_USER_WARNING = 512, /* User-generated warning message.*/
|
||||
E_USER_NOTICE = 1024, /* User-generated notice message.*/
|
||||
E_STRICT = 2048, /* Enable to have PHP suggest changes to your code which will ensure the best interoperability
|
||||
* and forward compatibility of your code.
|
||||
*/
|
||||
E_RECOVERABLE_ERROR = 4096, /* Catchable fatal error. It indicates that a probably dangerous error ocurred, but did not
|
||||
* leave the Engine in an unstable state. If the error is not caught by a user defined handle
|
||||
* the application aborts as it was an E_ERROR.
|
||||
*/
|
||||
E_DEPRECATED = 8192, /* Run-time notices. Enable this to receive warnings about code that will not
|
||||
* work in future versions.
|
||||
*/
|
||||
E_USER_DEPRECATED = 16384, /* User-generated warning message. */
|
||||
E_ALL = 32767 /* All errors and warnings */
|
||||
E_ERROR = 1, /* Fatal errors. These indicate errors that can not be recovered from,
|
||||
* such as a memory allocation problem or compile-time parse/syntax errors.
|
||||
* Execution of the script is halted. */
|
||||
E_WARNING = 2, /* Run-time warnings (non-fatal errors). Execution of the script is not halted. */
|
||||
E_NOTICE = 4, /* Run-time notices. Indicate that the script encountered something that could
|
||||
* indicate an error, but could also happen in the normal course of running a script. */
|
||||
E_DEPRECATED = 8 /* Run-time notices, informing about a code that will not work in future versions. */
|
||||
};
|
||||
/*
|
||||
* Each VM instruction resulting from compiling a PHP script is represented
|
||||
|
|
Loading…
Reference in New Issue