Built-in Exception Classes
Last updated
Last updated
The superclass of all exceptions.
Thrown when attempting to reserve too much memory at once.
Indicates a script error.
Thrown when an unimplemented feature is invoked.
Thrown by a syntax error.
Without a class specified, the rescue class will catch the subclasses of this exception class.
Thrown when argument numbers do not match or when the values are incorrect.
Thrown when the index is out of range.
Thrown when an I/O error occurs.
Thrown when EOF (End Of File) has been reached.
Thrown when no jump destination is found for a control structure.
Thrown when accessing an undefined local variable or constant.
Thrown when calling an undefined method.
Thrown when compiling a regular expression fails.
A runtime exception. Thrown when calling raise without specifying an exception.
Thrown when a system call fails.
Thrown when a stack level becomes too deep.
Thrown when an illegal type is invoked.
Thrown when dividing by zero.
Terminates the program. See exit for more information.
A fatal (internal) error. This object is not visible with normal methods.
A range exception. Thrown when an out-of-range integer conversion (from to ) , etc., occurs.
Thrown when trying to convert a positive or negative infinite number or NaN (Not a Number) into , or when comparing a number to a NaN.
Exception class for each errno. See the module for more on each class name.