Changeset 1402 for palm/trunk/SOURCE/message.f90
- Timestamp:
- May 9, 2014 2:25:13 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/SOURCE/message.f90
r1385 r1402 21 21 ! Current revisions: 22 22 ! ----------------- 23 ! 23 ! formatting of messages modified 24 24 ! 25 25 ! Former revisions: … … 83 83 pe_out_of_range = .FALSE. 84 84 85 ! print*, '#1'86 85 ! 87 86 !-- Create the complete output string, starting with the message level … … 97 96 ENDIF 98 97 99 ! print*, '#2'100 98 ! 101 99 !-- Add the message identifier and the generating routine … … 113 111 114 112 115 ! print*, '#3'116 113 ! 117 114 !-- Output the output string and the corresponding message string which had … … 124 121 do_output = .TRUE. 125 122 ENDIF 126 ! print*, '#4'127 123 #if defined( __parallel ) 128 124 ! … … 132 128 IF ( myid == 0 ) do_output = .TRUE. 133 129 ENDIF 134 ! print*, '#5'135 130 #endif 136 131 … … 138 133 !-- Now do the output 139 134 IF ( do_output ) THEN 140 ! print*, '#6' 135 141 136 IF ( file_id == 6 ) THEN 142 137 ! 143 138 !-- Output on stdout 144 139 WRITE( *, '(A/)' ) TRIM( header_string ) 145 ! print*, '#7'146 140 ! 147 141 !-- Cut message string into pieces and output one piece per line. … … 155 149 ENDDO 156 150 WRITE( *, '(4X,A)' ) TRIM( message_string ) 157 ! print*, '#8'158 151 WRITE( *, '(4X,A)' ) '' 159 152 WRITE( *, '(4X,A)' ) TRIM( information_string_1 ) … … 162 155 163 156 ELSE 164 ! print*, '#9'165 157 ! 166 158 !-- Output on requested file id (file must have been opened elsewhere!) … … 185 177 IF ( flush == 1 ) CALL local_flush( file_id ) 186 178 ENDIF 187 ! print*, '#10'188 179 189 180 IF ( pe_out_of_range ) THEN … … 195 186 WRITE ( *, '(A)' ) ' Output is done on PE0 instead' 196 187 ENDIF 197 ! print*, '#11'198 188 199 189 ENDIF … … 201 191 ! 202 192 !-- Abort execution, if requested 203 ! print*, '#12'204 193 IF ( requested_action > 0 ) THEN 205 194 abort_mode = requested_action 206 195 CALL local_stop 207 196 ENDIF 208 ! print*, '#13'209 197 210 198 END SUBROUTINE message 211 199 212 200 213 SUBROUTINE location_message( location )201 SUBROUTINE location_message( location, advance ) 214 202 215 203 !------------------------------------------------------------------------------! … … 219 207 !------------------------------------------------------------------------------! 220 208 209 USE, INTRINSIC :: ISO_FORTRAN_ENV, & 210 ONLY : OUTPUT_UNIT 211 221 212 USE pegrid, & 222 213 ONLY : myid … … 224 215 IMPLICIT NONE 225 216 226 CHARACTER(LEN=*) :: location 217 CHARACTER(LEN=*) :: location !: text to be output on stdout 218 LOGICAL :: advance !: switch for advancing/noadvancing I/O 227 219 228 220 229 221 IF ( myid == 0 ) THEN 230 WRITE ( 6, '(6X,''... '',A)' ) TRIM( location ) 231 CALL local_flush( 6 ) 222 IF ( advance ) THEN 223 WRITE ( OUTPUT_UNIT, '(6X,''--- '',A)' ) TRIM( location ) 224 ELSE 225 WRITE ( OUTPUT_UNIT, '(6X,''... '',A)', ADVANCE='NO' ) & 226 TRIM( location ) 227 ENDIF 228 CALL local_flush( OUTPUT_UNIT ) 232 229 ENDIF 233 230
Note: See TracChangeset
for help on using the changeset viewer.