``

prev Menu next

EXTYPE function

EXTYPE
returns the number that means the exception type.
EXTYPE can be written only in an exception handler.
Note. EXTYPE is a reserved word.

Principal EXTYPEs

    1000 level Overflow
      1002 Overflow in a numeric expression
      1003 Overflow in a numeric supplied function
      1004 Overflow in a VAL function
      1005 Overflow in a numeric array
      1006 Overflow in a READ statement
      1008 Overflow in a file input
      1009 Overflow in a DET or DOT function
    2000 level Subscript Errors
      2001 Subscript out of bounds
    3000 level Math Errors
      3001 Division by zero
      3002 Negative to the non-integral power
      3003 Zero to the negative power
      3004 Logarithm of zero or negative
      3005 SQR of a negative number
      3006 Zero divisor in MOD or REMAINDER
      3007 Out of range in ACOS or ASIN
      3008 ANGLE(0,0)
      3009 INV of a singular matrix
    4000 level Parameter Errors
      4001 VAL of non-numeric-constant
      4002 CHR$ Out of Range
      4003 ORD Out of Range
      ････
    5000 level Array Storage Errors
    6000 level Matrix Errors
    7000 level File Usage Errors
    8000 level I/O Errors
      8001 READ out of data
      8011 End of File
      8012 Too Few Data in a record
      8013 Too Many Data in a record
      8101 Non-numeric constant on file input
      8105 Syntactically incorrect input reply from file
      8120 Type Mismatch on INTERNAL input
      8201 Incorrect Format String
      8202 No Format Item
      8401 Timeout on INPUT
    9000 level Device Errors
    10000 level Control Errors
    11000 level Graphics Errors

See also Nonfatal Errors.
Implementation defined EXTYPEs
`-3009 Invalid operation on transformation
-1005 Overflow on transformation
-103 Out of Memory for Arrays
-102 Out of memory for Simple Variables
-101 System Stack Overflow
-100 Out of memory for the execution
7101 Incorrect File Description
7102 File Not Exist
9003 Failed to Delete File
9004 File Already Exist
`

Propagation of Exception
If an exception is propagated out of the procedure, EXTYPE becomes the value obtained by adding 100000 to the initial extype, while if the initial extype is negative, EXTYPE becomes the value obtained by subtracting 100000 from it.
Note.
The extype before propagated can be obtained using `REMAINDER(EXTYPE,100000)`.