Module contains error handling procedures
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
integer(kind=i32), | public, | parameter | :: | IO_OPEN | = | 1 | Constant for file open used by fErr |
integer(kind=i32), | public, | parameter | :: | IO_READ | = | 2 | Constant for file read used by fErr |
integer(kind=i32), | public, | parameter | :: | IO_WRITE | = | 3 | Constant for file write used by fErr |
integer(kind=i32), | public, | parameter | :: | IO_CLOSE | = | 4 | Constant for file close used by fErr |
Checks for successful (de)allocation. Stops the code.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=i32), | intent(in) | :: | istat | results of stat=istat in (de)allocate |
||
character(len=*), | intent(in) | :: | aMsg | Message associated with the (de)allocate |
||
integer(kind=i32), | intent(in) | :: | alloc | 1 = allocate, 2 = deallocate |
||
integer(kind=i32), | intent(in), | optional | :: | iunit | Optional file id to write the message to |
Write a message
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
character(len=*), | intent(in) | :: | aMsg | Message to write |
||
integer(kind=i32), | intent(in), | optional | :: | iunit | file id to write the message to |
Write a Warning message
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
character(len=*), | intent(in) | :: | aMsg | Message to write |
||
integer(kind=i32), | intent(in), | optional | :: | iunit | file id to write the message to |
Write an Error message. Stops the code
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
character(len=*), | intent(in) | :: | aMsg | Message to write |
||
integer(kind=i32), | intent(in), | optional | :: | iunit | file id to write the message to |
Checks for a file error
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=i32), | intent(in) | :: | istat | Result of iostat=istat for open,read,write,close |
||
character(len=*), | intent(in) | :: | fname | Name of the file |
||
integer(kind=i32), | intent(in) | :: | flg | IO_OPEN=Open, IO_READ=Read, IO_WRITE=Write, IO_CLOSE=Close |
||
integer(kind=i32), | intent(in), | optional | :: | iunit | file id to write the error to |