From 5dbe3f109c557d01fb5fbbfb93c12a432c855ca3 Mon Sep 17 00:00:00 2001 From: Martin Diehl Date: Sun, 4 Feb 2024 06:53:41 +0100 Subject: [PATCH] not used comment signs depend on file format, so better implement specific variants if needed instead of relying on central functionality --- src/IO.f90 | 23 ----------------------- 1 file changed, 23 deletions(-) diff --git a/src/IO.f90 b/src/IO.f90 index 1515df6f1..9e3b770b1 100644 --- a/src/IO.f90 +++ b/src/IO.f90 @@ -25,15 +25,12 @@ implicit none(type,external) IO_QUOTES = "'"//'"' character, parameter, public :: & IO_EOL = LF !< end of line character - character, parameter :: & - IO_COMMENT = '#' public :: & IO_init, & IO_selfTest, & IO_read, & IO_readlines, & - IO_isBlank, & IO_wrapLines, & IO_strPos, & IO_strValue, & @@ -149,22 +146,6 @@ function IO_read(fileName) result(fileContent) end function IO_read -!-------------------------------------------------------------------------------------------------- -!> @brief Identifiy strings without content. -!-------------------------------------------------------------------------------------------------- -logical pure function IO_isBlank(str) - - character(len=*), intent(in) :: str !< string to check for content - - integer :: posNonBlank - - - posNonBlank = verify(str,IO_WHITESPACE) - IO_isBlank = posNonBlank == 0 .or. posNonBlank == scan(str,IO_COMMENT) - -end function IO_isBlank - - !-------------------------------------------------------------------------------------------------- !> @brief Insert EOL at separator trying to keep line length below limit. !-------------------------------------------------------------------------------------------------- @@ -845,10 +826,6 @@ subroutine IO_selfTest() 'A'//LF//'B'//LF) error stop 'CRLF2LF/4' if (CRLF2LF('A'//LF//CR//'B') /= 'A'//LF//CR//'B') error stop 'CRLF2LF/5' - str=' '; if (.not. IO_isBlank(str)) error stop 'IO_isBlank/1' - str=' #isBlank';if (.not. IO_isBlank(str)) error stop 'IO_isBlank/2' - str=' i#s'; if ( IO_isBlank(str)) error stop 'IO_isBlank/3' - str='*(HiU!)3';if ('*(hiu!)3' /= IO_lc(str)) error stop 'IO_lc' if ('abc, def' /= IO_wrapLines('abc, def')) &