unknown error/warning numbers are internal errors

This commit is contained in:
Martin Diehl 2022-05-27 08:34:52 +02:00
parent f90523eb07
commit f31dd8cbe8
1 changed files with 3 additions and 4 deletions

View File

@ -540,10 +540,8 @@ subroutine IO_error(error_ID,el,ext_msg)
case (950)
msg = 'max number of cut back exceeded, terminating'
!-------------------------------------------------------------------------------------------------
! general error messages
case default
msg = 'unknown error number...'
error stop 'invalid error number'
end select
@ -599,7 +597,7 @@ subroutine IO_warning(warning_ID,ext_msg,label1,ID1,label2,ID2)
case (709)
msg = 'read only the first document'
case default
msg = 'unknown warning number'
error stop 'invalid warning number'
end select
!$OMP CRITICAL (write2out)
@ -667,6 +665,7 @@ subroutine selfTest()
integer, dimension(:), allocatable :: chunkPos
character(len=:), allocatable :: str
if(dNeq(1.0_pReal, IO_stringAsFloat('1.0'))) error stop 'IO_stringAsFloat'
if(dNeq(1.0_pReal, IO_stringAsFloat('1e0'))) error stop 'IO_stringAsFloat'
if(dNeq(0.1_pReal, IO_stringAsFloat('1e-1'))) error stop 'IO_stringAsFloat'