psmile_assert.F90

Go to the documentation of this file.
00001 !-----------------------------------------------------------------------
00002 ! Copyright 2006-2010, NEC Europe Ltd., London, UK.
00003 ! All rights reserved. Use is subject to OASIS4 license terms.
00004 !-----------------------------------------------------------------------
00005 !BOP
00006 !
00007 ! !ROUTINE: PSMILe_Assert
00008 !
00009 ! !INTERFACE:
00010 !
00011       subroutine psmile_assert (file, line, msg)
00012 !
00013 ! !USES:
00014 !
00015       use PSMILe, dummy_interface => PSMILe_Assert
00016 
00017       implicit none
00018 !
00019 ! !INPUT PARAMETERS:
00020 !
00021       character(len=*), Intent(In)   :: file
00022 
00023 !     File from which psmile_abort has been called
00024 
00025       character(len=*), Intent(In)   :: msg
00026 
00027 !     Developers message
00028 
00029       integer, Intent(In)            :: line
00030 
00031 !     Linenumber in "file" from which abort was called
00032 !
00033 ! !DESCRIPTION:
00034 !
00035 !  Internal Control Routine of PSMILe Library
00036 !
00037 !  Subroutine "PSMILe_Assert" prints data on assertion violations in
00038 !  Fortran programs of the PSMILe library.
00039 !
00040 ! !REVISION HISTORY:
00041 !
00042 !   Date      Programmer   Description
00043 ! ----------  ----------   -----------
00044 ! 01.12.03    H. Ritzdorf  created
00045 !
00046 !EOP
00047 !-----------------------------------------------------------------------
00048 !
00049 !  $Id: psmile_assert.F90 2325 2010-04-21 15:00:07Z valcke $
00050 !  $Autor$
00051 
00052    Character(len=len_cvs_string), save :: mycvs = 
00053        '$Id: psmile_assert.F90 2325 2010-04-21 15:00:07Z valcke $'
00054 !
00055 ! -----------------------------------------------------------------------
00056 !
00057 !===> Print out assertion violation
00058 !
00059 
00060       write (*, 9990)  Appl%rank, trim(file), line, &
00061                       trim(Appl%name), trim(msg)
00062 
00063       call psmile_flushstd
00064 
00065       call psmile_abort
00066 
00067 9990  format (1x, '[', i3, '] !!! Assertion violation: ', a, &
00068                   ': line', i6                               &
00069              /1x, 'component: ', a                           &
00070              /1x, 'message:   ', a)
00071 
00072       end subroutine PSMILe_Assert

Generated on 18 Mar 2011 for Oasis4 by  doxygen 1.6.1