Opcode errors are errors encountered during I.F. function
execution. Not to be confused with errors encountered and reported by one
of the BAR engine's interfacial objects using Get_Last_Error, these
errors are more technical in nature and only occur under very specific
circumstances.
An opcode error is generated as a result of a critical error when
calling an I.F. function directly or indirectly. This includes direct
calls using BAR::Global_Function_Call and BAR::Member_Function_Call,
and indirect calls that happen as a result of the I.F.'s deserialization
or serialization critical steps.
Opcode error codes are defined below.
-
0:
NO_OPCODE_ERROR
-
1:
END_PROCESSING
-
2:
END_BREAKPOINT
-
3:
INVALID_OPCODE
-
4:
INVALID_REG_SLOT
-
5:
FIRST_REG_CANNOT_BE_PTR
-
6:
FIRST_REG_INVALID_PTR
-
7:
SECOND_REG_INVALID_PTR
-
8:
BAD_NEW_BUFFER_CONTEXT
-
9:
INVALID_UNARY_MOD
-
10:
FIRST_REG_MUST_BE_POSITIVE
-
11:
DOMAIN_ERROR_TAN
-
12:
DOMAIN_ERROR_LOG10
-
13:
DOMAIN_ERROR_LOG
-
14:
DOMAIN_ERROR_SQRT
-
15:
DOMAIN_ERROR_ZERO_DIVISOR
-
16:
INVALID_STRUCT_UID
-
17:
DOMAIN_ERROR_POWR
-
18:
FIRST_REG_MUST_BE_PTR
-
19:
SCALE_FACTOR_MUST_BE_POSITIVE
-
20:
MEMBER_SCOPE_REQUIRED
-
21:
INVALID_ADDRESS
-
22:
INVALID_SIZE
-
23:
INVALID_GLOBAL_VAR_UID
-
24:
POINTER_TYPE_MISMATCH
-
25:
POINTER_TYPE_NOT_ALLOWED
-
26:
INVALID_MEMBER_NUMBER
-
27:
INVALID_PARAM_NUMBER
-
28:
INVALID_LOCAL_NUMBER
-
29:
INVALID_ARRAY_INDEX
-
30:
GLOBAL_MUST_BE_ARRAY
-
31:
INVALID_LABEL_COUNT
-
32:
INVALID_SCRIPT_ADDRESS
-
33:
FUNCTION_NOT_PREPARED
-
34:
PARAMETER_COUNT_MISMATCH
-
35:
NEED_BUILT_IN_FUNCTION
-
36:
NEED_NON_BUILT_IN_FUNCTION
-
37:
INVALID_FUNC_UID
-
38:
STACK_OVERFLOW
-
39:
BAR_BAD_CONVERTED_POINTER
-
40:
SESSION_CYCLE_LIMIT
-
41:
INVALID_CONSTRUCT_UID
-
42:
INVALID_NEW_BUFFER_SIZE
-
43:
INVALID_NODE_POINTER
-
44:
INVALID_PTR2CONSTANT
-
45:
POINTER_TO_CONTAINER_OF_POINTERS
-
46:
INVALID_BIT_FIELD_STRUCT_UID
-
47:
INVALID_NAV_MOD
-
48:
INADEQUATE_MEMBER_SCOPE_SPACE
-
49:
INVALID_SPECCALL_PARAM
-
50:
BLOCKSIZE_OUT_OF_RANGE
-
51:
OFFSETTWEAK_OUT_OF_RANGE
-
52:
DESERIALIZE_OUT_OF_RANGE
-
53: SERIALIZE_OUT_OF_RANGE
Making sense of these opcode errors is not a trivial task. Of these
errors, of course, the last several are ones to which you should pay the most
attention. The codes BLOCKSIZE_OUT_OF_RANGE, OFFSETTWEAK_OUT_OF_RANGE,
DESERIALIZE_OUT_OF_RANGE, and SERIALIZE_OUT_OF_RANGE
are returned when a critical-step function returns an out-of-range value during
a particular routine (i.e. BlockSize, OffsetTweak, Deserialize, and Serialize).
The code NO_OPCODE_ERROR indicates no error condition.
The code END_PROCESSING indicates a successful opcode
execution session (also no error condition).
The code END_BREAKPOINT indicates a breakpoint was encountered
in the function body.
See also: [BAR
interfacial function reference]
|