The current error context is
checked for any error messages reported since the context was created or last annulled. If none exist,
STATUS is returned set to SAI__OK. If there are any such messages, STATUS is returned
set to the status value associated with the last reported error message.
ERR_STAT( STATUS )
STATUS = INTEGER (Returned)
The last reported error
status within the current error context; if none exist, STATUS is returned set to SAI__OK.