diff --git a/src/IO.f90 b/src/IO.f90 index a76959a44..4b962bd1e 100644 --- a/src/IO.f90 +++ b/src/IO.f90 @@ -684,7 +684,11 @@ function IO_stringValue(string,chunkPos,myChunk,silent) logical :: warn - warn = merge(silent,.false.,present(silent)) + if (present(silent)) then + warn = silent + else + warn = .false. + endif IO_stringValue = '' valuePresent: if (myChunk > chunkPos(1) .or. myChunk < 1_pInt) then diff --git a/src/config.f90 b/src/config.f90 index 4d5a76432..7ae800f30 100644 --- a/src/config.f90 +++ b/src/config.f90 @@ -513,8 +513,12 @@ character(len=65536) function getString(this,key,defaultVal,raw) type(tPartitionedStringList), pointer :: item logical :: found, & whole + if (present(raw)) then + whole = raw + else + whole = .false. + endif - whole = merge(raw,.false.,present(raw)) ! whole string or white space splitting found = present(defaultVal) if (found) then getString = trim(defaultVal) @@ -661,7 +665,11 @@ function getStrings(this,key,defaultVal,requiredShape,raw) cumulative cumulative = (key(1:1) == '(' .and. key(len_trim(key):len_trim(key)) == ')') - whole = merge(raw,.false.,present(raw)) + if (present(raw)) then + whole = raw + else + whole = .false. + endif found = .false. item => this