SysError

Usage

use SysError;

or

import SysError;

This module helps handle system errors.

This module defines the type syserr, which can encode an error code or error message and be returned from routines generating an error. Additional routines are provided to print a useful error message from a syserr.

The IO module uses these routines in a way that supports error inspection and rapid prototyping. Most routines in the IO module have two forms. In one form, a OS.SystemError is thrown when an error occurs. In the second form, a syserr is returned in an out error argument.

Warning

The ‘SysError’ module is deprecated. Please use ‘OS’ instead