Report Typos and Errors    
Semi-Lagrangian Library
Modular library for kinetic and gyrokinetic simulations of plasmas in fusion energy devices.
sll_m_memory.F90
Go to the documentation of this file.
1 !**************************************************************
2 ! Copyright INRIA
3 ! Authors :
4 ! CALVI project team
5 !
6 ! This code SeLaLib (for Semi-Lagrangian-Library)
7 ! is a parallel library for simulating the plasma turbulence
8 ! in a tokamak.
9 !
10 ! This software is governed by the CeCILL-B license
11 ! under French law and abiding by the rules of distribution
12 ! of free software. You can use, modify and redistribute
13 ! the software under the terms of the CeCILL-B license as
14 ! circulated by CEA, CNRS and INRIA at the following URL
15 ! "http://www.cecill.info".
16 !**************************************************************
17 
18 !------------------------------------------------------------------------------
19 ! SELALIB
20 !------------------------------------------------------------------------------
21 !
22 ! MODULE: sll_m_memory
23 !
30 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
31  implicit none
32 
33  public :: &
35 
36  private
37 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
38 
39 ! Useful for 'alternative implementation'. Ignore for now.
40 #if 0
41  interface sll_allocate
42  module procedure sll_allocate_int_1d, sll_allocate_real_1d, &
43  sll_allocate_complex_1d
44  end interface
45 #endif
46 
47 contains
48 
49  !---------------------------------------------------------------------------
61  !---------------------------------------------------------------------------
62 
63  subroutine sll_s_test_error_code(err_code, descriptor, file_name, line_number)
64  integer :: err_code
65  character(len=*), intent(in) :: descriptor
66  character(len=*), intent(in) :: file_name
67  integer, intent(in) :: line_number
68  if (err_code .ne. 0) then
69  write (*, '(a, a, i8)') descriptor, ' Triggered in FILE '//file_name// &
70  ', in LINE: ', line_number
71  stop 'ERROR: sll_s_test_error_code(): exiting program'
72  end if
73  end subroutine sll_s_test_error_code
74 
75 end module sll_m_memory
Implements the error testing function and other related functionalities.
subroutine, public sll_s_test_error_code(err_code, descriptor, file_name, line_number)
Test if there is an error and write it on the screen.
    Report Typos and Errors