https://www.cdslab.org/paramonte/fortran/2
Current view: top level - main - pm_arrayReplace.F90 (source / functions) Hit Total Coverage
Test: ParaMonte 2.0.0 :: Serial Fortran - Code Coverage Report Lines: 17 17 100.0 %
Date: 2024-04-08 03:18:57 Functions: 1 1 100.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
       2             : !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
       3             : !!!!                                                                                                                            !!!!
       4             : !!!!    ParaMonte: Parallel Monte Carlo and Machine Learning Library.                                                           !!!!
       5             : !!!!                                                                                                                            !!!!
       6             : !!!!    Copyright (C) 2012-present, The Computational Data Science Lab                                                          !!!!
       7             : !!!!                                                                                                                            !!!!
       8             : !!!!    This file is part of the ParaMonte library.                                                                             !!!!
       9             : !!!!                                                                                                                            !!!!
      10             : !!!!    LICENSE                                                                                                                 !!!!
      11             : !!!!                                                                                                                            !!!!
      12             : !!!!       https://github.com/cdslaborg/paramonte/blob/main/LICENSE.md                                                          !!!!
      13             : !!!!                                                                                                                            !!!!
      14             : !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
      15             : !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
      16             : 
      17             : !>  \brief
      18             : !>  This module contains procedures and generic interfaces for replacing patterns within arrays of various types.<br>
      19             : !>
      20             : !>  \benchmarks
      21             : !>
      22             : !>  \benchmark{getReplaced_vs_setReplaced, The runtime performance of [getReplaced](@ref pm_arrayReplace::getReplaced) vs. [setReplaced](@ref pm_arrayReplace::setReplaced)}
      23             : !>  \include{lineno} benchmark/pm_arrayReplace/getReplaced_vs_setReplaced/main.F90
      24             : !>  \compilefb{getReplaced_vs_setReplaced}
      25             : !>  \postprocb{getReplaced_vs_setReplaced}
      26             : !>  \include{lineno} benchmark/pm_arrayReplace/getReplaced_vs_setReplaced/main.py
      27             : !>  \visb{getReplaced_vs_setReplaced}
      28             : !>  \image html benchmark/pm_arrayReplace/getReplaced_vs_setReplaced/benchmark.getReplaced_vs_setReplaced.runtime.png width=1000
      29             : !>  \image html benchmark/pm_arrayReplace/getReplaced_vs_setReplaced/benchmark.getReplaced_vs_setReplaced.runtime.ratio.png width=1000
      30             : !>  \moralb{getReplaced_vs_setReplaced}
      31             : !>      -#  The procedures under the generic interface [getReplaced](@ref pm_arrayReplace::getReplaced) are functions while
      32             : !>          the procedures under the generic interface [setReplaced](@ref pm_arrayReplace::setReplaced) are subroutines.<br>
      33             : !>          From the benchmark results, it appears that the functional interface performs slightly less efficiently than the subroutine interface.<br>
      34             : !>          Note that this benchmark does not even include the cost of repeated reallcations, that is, the allocation of `Replaced` happen only once in all tests.<br>
      35             : !>      -#  Furthermore, the recursive `getReplaced()` implementation with recursive allocations appears to be 3-33 times
      36             : !>          slower than the subroutine implementation, depending on the size of the array within which the pattern is to be replaced.<br>
      37             : !>      -#  Note that this benchmark considers the worst-case scenario where all elements of the input `array` match the
      38             : !>          input `pattern` and must be therefore, replaced.<br>
      39             : !>
      40             : !>  \see
      41             : !>  [pm_arrayInsert](@ref pm_arrayInsert)<br>
      42             : !>  [pm_arrayRemove](@ref pm_arrayRemove)<br>
      43             : !>
      44             : !>  \test
      45             : !>  [test_pm_arrayReplace](@ref test_pm_arrayReplace)
      46             : !>
      47             : !>  \finmain
      48             : !>
      49             : !>  \author
      50             : !>  \FatemehBagheri, Wednesday 12:20 AM, October 13, 2021, Dallas, TX
      51             : 
      52             : !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
      53             : 
      54             : module pm_arrayReplace
      55             : 
      56             :     use pm_kind, only: SK, IK, LK
      57             : 
      58             :     implicit none
      59             : 
      60             :     character(*, SK), parameter :: MODULE_NAME = "@pm_arrayReplace"
      61             : 
      62             : !>  \cond excluded
      63             : !   \bug
      64             : !   The following bypasses the bug reported below that creates a conflict between Intel and gfortran.
      65             : #if     __INTEL_COMPILER
      66             : #define LEN_ARRAY :
      67             : #else
      68             : #define LEN_ARRAY len(array)
      69             : #endif
      70             : !>  \endcond excluded
      71             : 
      72             : !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
      73             : 
      74             :    !abstract interface
      75             :    !function iseq_proc_CK3(object1, object2) result(equivalent)
      76             :    !    use pm_kind, only: CK => CK3
      77             :    !    complex(CK) , intent(in)    :: Object1(:), Object2(:)
      78             :    !    logical(LK)                 :: equivalent
      79             :    !end function
      80             :    !end interface
      81             : 
      82             : !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
      83             : 
      84             :     !>  \cond excluded
      85             : #if 0
      86             :     !   gfortran 11 cannot run examples that contain procedure dummy arguments with explicit interface,
      87             :     !   yielding the following error: Fortran runtime error: array bound mismatch for dimension 1 of array 'segment' (0/7021782950660276225)
      88             :     !   Intel ifort 2021.6 can successfully compile and run the examples.
      89             :     abstract interface
      90             : 
      91             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
      92             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
      93             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
      94             : 
      95             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
      96             : 
      97             : #if SK5_ENABLED
      98             :     function iseq_D0_D0_SK5(segment, pattern) result(equivalent)
      99             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     100             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_SK5
     101             : #endif
     102             :         use pm_kind, only: LK, SKC => SK5
     103             :         character(*,SKC)        , intent(in)                    :: segment
     104             :         character(*,SKC)        , intent(in)                    :: pattern
     105             :         logical(LK)                                             :: equivalent
     106             :     end function
     107             : #endif
     108             : 
     109             : #if SK4_ENABLED
     110             :     function iseq_D0_D0_SK4(segment, pattern) result(equivalent)
     111             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     112             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_SK4
     113             : #endif
     114             :         use pm_kind, only: LK, SKC => SK4
     115             :         character(*,SKC)        , intent(in)                    :: segment
     116             :         character(*,SKC)        , intent(in)                    :: pattern
     117             :         logical(LK)                                             :: equivalent
     118             :     end function
     119             : #endif
     120             : 
     121             : #if SK3_ENABLED
     122             :     function iseq_D0_D0_SK3(segment, pattern) result(equivalent)
     123             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     124             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_SK3
     125             : #endif
     126             :         use pm_kind, only: LK, SKC => SK3
     127             :         character(*,SKC)        , intent(in)                    :: segment
     128             :         character(*,SKC)        , intent(in)                    :: pattern
     129             :         logical(LK)                                             :: equivalent
     130             :     end function
     131             : #endif
     132             : 
     133             : #if SK2_ENABLED
     134             :     function iseq_D0_D0_SK2(segment, pattern) result(equivalent)
     135             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     136             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_SK2
     137             : #endif
     138             :         use pm_kind, only: LK, SKC => SK2
     139             :         character(*,SKC)        , intent(in)                    :: segment
     140             :         character(*,SKC)        , intent(in)                    :: pattern
     141             :         logical(LK)                                             :: equivalent
     142             :     end function
     143             : #endif
     144             : 
     145             : #if SK1_ENABLED
     146             :     function iseq_D0_D0_SK1(segment, pattern) result(equivalent)
     147             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     148             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_SK1
     149             : #endif
     150             :         use pm_kind, only: LK, SKC => SK1
     151             :         character(*,SKC)        , intent(in)                    :: segment
     152             :         character(*,SKC)        , intent(in)                    :: pattern
     153             :         logical(LK)                                             :: equivalent
     154             :     end function
     155             : #endif
     156             : 
     157             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     158             : 
     159             : #if IK5_ENABLED
     160             :     function iseq_D0_D0_IK5(segment, pattern) result(equivalent)
     161             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     162             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_IK5
     163             : #endif
     164             :         use pm_kind, only: LK, IKC => IK5
     165             :         integer(IKC)            , intent(in)                    :: segment
     166             :         integer(IKC)            , intent(in)                    :: pattern
     167             :         logical(LK)                                             :: equivalent
     168             :     end function
     169             : #endif
     170             : 
     171             : #if IK4_ENABLED
     172             :     function iseq_D0_D0_IK4(segment, pattern) result(equivalent)
     173             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     174             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_IK4
     175             : #endif
     176             :         use pm_kind, only: LK, IKC => IK4
     177             :         integer(IKC)            , intent(in)                    :: segment
     178             :         integer(IKC)            , intent(in)                    :: pattern
     179             :         logical(LK)                                             :: equivalent
     180             :     end function
     181             : #endif
     182             : 
     183             : #if IK3_ENABLED
     184             :     function iseq_D0_D0_IK3(segment, pattern) result(equivalent)
     185             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     186             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_IK3
     187             : #endif
     188             :         use pm_kind, only: LK, IKC => IK3
     189             :         integer(IKC)            , intent(in)                    :: segment
     190             :         integer(IKC)            , intent(in)                    :: pattern
     191             :         logical(LK)                                             :: equivalent
     192             :     end function
     193             : #endif
     194             : 
     195             : #if IK2_ENABLED
     196             :     function iseq_D0_D0_IK2(segment, pattern) result(equivalent)
     197             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     198             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_IK2
     199             : #endif
     200             :         use pm_kind, only: LK, IKC => IK2
     201             :         integer(IKC)            , intent(in)                    :: segment
     202             :         integer(IKC)            , intent(in)                    :: pattern
     203             :         logical(LK)                                             :: equivalent
     204             :     end function
     205             : #endif
     206             : 
     207             : #if IK1_ENABLED
     208             :     function iseq_D0_D0_IK1(segment, pattern) result(equivalent)
     209             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     210             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_IK1
     211             : #endif
     212             :         use pm_kind, only: LK, IKC => IK1
     213             :         integer(IKC)            , intent(in)                    :: segment
     214             :         integer(IKC)            , intent(in)                    :: pattern
     215             :         logical(LK)                                             :: equivalent
     216             :     end function
     217             : #endif
     218             : 
     219             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     220             : 
     221             : #if LK5_ENABLED
     222             :     function iseq_D0_D0_LK5(segment, pattern) result(equivalent)
     223             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     224             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_LK5
     225             : #endif
     226             :         use pm_kind, only: LK, LKC => LK5
     227             :         logical(LKC)            , intent(in)                    :: segment
     228             :         logical(LKC)            , intent(in)                    :: pattern
     229             :         logical(LK)                                             :: equivalent
     230             :     end function
     231             : #endif
     232             : 
     233             : #if LK4_ENABLED
     234             :     function iseq_D0_D0_LK4(segment, pattern) result(equivalent)
     235             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     236             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_LK4
     237             : #endif
     238             :         use pm_kind, only: LK, LKC => LK4
     239             :         logical(LKC)            , intent(in)                    :: segment
     240             :         logical(LKC)            , intent(in)                    :: pattern
     241             :         logical(LK)                                             :: equivalent
     242             :     end function
     243             : #endif
     244             : 
     245             : #if LK3_ENABLED
     246             :     function iseq_D0_D0_LK3(segment, pattern) result(equivalent)
     247             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     248             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_LK3
     249             : #endif
     250             :         use pm_kind, only: LK, LKC => LK3
     251             :         logical(LKC)            , intent(in)                    :: segment
     252             :         logical(LKC)            , intent(in)                    :: pattern
     253             :         logical(LK)                                             :: equivalent
     254             :     end function
     255             : #endif
     256             : 
     257             : #if LK2_ENABLED
     258             :     function iseq_D0_D0_LK2(segment, pattern) result(equivalent)
     259             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     260             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_LK2
     261             : #endif
     262             :         use pm_kind, only: LK, LKC => LK2
     263             :         logical(LKC)            , intent(in)                    :: segment
     264             :         logical(LKC)            , intent(in)                    :: pattern
     265             :         logical(LK)                                             :: equivalent
     266             :     end function
     267             : #endif
     268             : 
     269             : #if LK1_ENABLED
     270             :     function iseq_D0_D0_LK1(segment, pattern) result(equivalent)
     271             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     272             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_LK1
     273             : #endif
     274             :         use pm_kind, only: LK, LKC => LK1
     275             :         logical(LKC)            , intent(in)                    :: segment
     276             :         logical(LKC)            , intent(in)                    :: pattern
     277             :         logical(LK)                                             :: equivalent
     278             :     end function
     279             : #endif
     280             : 
     281             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     282             : 
     283             : #if CK5_ENABLED
     284             :     function iseq_D0_D0_CK5(segment, pattern) result(equivalent)
     285             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     286             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_CK5
     287             : #endif
     288             :         use pm_kind, only: LK, CKC => CK5
     289             :         complex(CKC)            , intent(in)                    :: segment
     290             :         complex(CKC)            , intent(in)                    :: pattern
     291             :         logical(LK)                                             :: equivalent
     292             :     end function
     293             : #endif
     294             : 
     295             : #if CK4_ENABLED
     296             :     function iseq_D0_D0_CK4(segment, pattern) result(equivalent)
     297             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     298             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_CK4
     299             : #endif
     300             :         use pm_kind, only: LK, CKC => CK4
     301             :         complex(CKC)            , intent(in)                    :: segment
     302             :         complex(CKC)            , intent(in)                    :: pattern
     303             :         logical(LK)                                             :: equivalent
     304             :     end function
     305             : #endif
     306             : 
     307             : #if CK3_ENABLED
     308             :     function iseq_D0_D0_CK3(segment, pattern) result(equivalent)
     309             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     310             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_CK3
     311             : #endif
     312             :         use pm_kind, only: LK, CKC => CK3
     313             :         complex(CKC)            , intent(in)                    :: segment
     314             :         complex(CKC)            , intent(in)                    :: pattern
     315             :         logical(LK)                                             :: equivalent
     316             :     end function
     317             : #endif
     318             : 
     319             : #if CK2_ENABLED
     320             :     function iseq_D0_D0_CK2(segment, pattern) result(equivalent)
     321             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     322             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_CK2
     323             : #endif
     324             :         use pm_kind, only: LK, CKC => CK2
     325             :         complex(CKC)            , intent(in)                    :: segment
     326             :         complex(CKC)            , intent(in)                    :: pattern
     327             :         logical(LK)                                             :: equivalent
     328             :     end function
     329             : #endif
     330             : 
     331             : #if CK1_ENABLED
     332             :     function iseq_D0_D0_CK1(segment, pattern) result(equivalent)
     333             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     334             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_CK1
     335             : #endif
     336             :         use pm_kind, only: LK, CKC => CK1
     337             :         complex(CKC)            , intent(in)                    :: segment
     338             :         complex(CKC)            , intent(in)                    :: pattern
     339             :         logical(LK)                                             :: equivalent
     340             :     end function
     341             : #endif
     342             : 
     343             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     344             : 
     345             : #if RK5_ENABLED
     346             :     function iseq_D0_D0_RK5(segment, pattern) result(equivalent)
     347             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     348             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_RK5
     349             : #endif
     350             :         use pm_kind, only: LK, RKC => RK5
     351             :         real(RKC)               , intent(in)                    :: segment
     352             :         real(RKC)               , intent(in)                    :: pattern
     353             :         logical(LK)                                             :: equivalent
     354             :     end function
     355             : #endif
     356             : 
     357             : #if RK4_ENABLED
     358             :     function iseq_D0_D0_RK4(segment, pattern) result(equivalent)
     359             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     360             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_RK4
     361             : #endif
     362             :         use pm_kind, only: LK, RKC => RK4
     363             :         real(RKC)               , intent(in)                    :: segment
     364             :         real(RKC)               , intent(in)                    :: pattern
     365             :         logical(LK)                                             :: equivalent
     366             :     end function
     367             : #endif
     368             : 
     369             : #if RK3_ENABLED
     370             :     function iseq_D0_D0_RK3(segment, pattern) result(equivalent)
     371             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     372             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_RK3
     373             : #endif
     374             :         use pm_kind, only: LK, RKC => RK3
     375             :         real(RKC)               , intent(in)                    :: segment
     376             :         real(RKC)               , intent(in)                    :: pattern
     377             :         logical(LK)                                             :: equivalent
     378             :     end function
     379             : #endif
     380             : 
     381             : #if RK2_ENABLED
     382             :     function iseq_D0_D0_RK2(segment, pattern) result(equivalent)
     383             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     384             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_RK2
     385             : #endif
     386             :         use pm_kind, only: LK, RKC => RK2
     387             :         real(RKC)               , intent(in)                    :: segment
     388             :         real(RKC)               , intent(in)                    :: pattern
     389             :         logical(LK)                                             :: equivalent
     390             :     end function
     391             : #endif
     392             : 
     393             : #if RK1_ENABLED
     394             :     function iseq_D0_D0_RK1(segment, pattern) result(equivalent)
     395             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     396             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D0_D0_RK1
     397             : #endif
     398             :         use pm_kind, only: LK, RKC => RK1
     399             :         real(RKC)               , intent(in)                    :: segment
     400             :         real(RKC)               , intent(in)                    :: pattern
     401             :         logical(LK)                                             :: equivalent
     402             :     end function
     403             : #endif
     404             : 
     405             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     406             : 
     407             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     408             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     409             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     410             : 
     411             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     412             : 
     413             : #if SK5_ENABLED
     414             :     function iseq_D1_D1_SK5(segment, pattern) result(equivalent)
     415             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     416             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_SK5
     417             : #endif
     418             :         use pm_kind, only: LK, SKC => SK5
     419             :         character(*,SKC)        , intent(in)    , contiguous    :: segment(:)
     420             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
     421             :         logical(LK)                                             :: equivalent
     422             :     end function
     423             : #endif
     424             : 
     425             : #if SK4_ENABLED
     426             :     function iseq_D1_D1_SK4(segment, pattern) result(equivalent)
     427             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     428             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_SK4
     429             : #endif
     430             :         use pm_kind, only: LK, SKC => SK4
     431             :         character(*,SKC)        , intent(in)    , contiguous    :: segment(:)
     432             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
     433             :         logical(LK)                                             :: equivalent
     434             :     end function
     435             : #endif
     436             : 
     437             : #if SK3_ENABLED
     438             :     function iseq_D1_D1_SK3(segment, pattern) result(equivalent)
     439             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     440             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_SK3
     441             : #endif
     442             :         use pm_kind, only: LK, SKC => SK3
     443             :         character(*,SKC)        , intent(in)    , contiguous    :: segment(:)
     444             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
     445             :         logical(LK)                                             :: equivalent
     446             :     end function
     447             : #endif
     448             : 
     449             : #if SK2_ENABLED
     450             :     function iseq_D1_D1_SK2(segment, pattern) result(equivalent)
     451             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     452             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_SK2
     453             : #endif
     454             :         use pm_kind, only: LK, SKC => SK2
     455             :         character(*,SKC)        , intent(in)    , contiguous    :: segment(:)
     456             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
     457             :         logical(LK)                                             :: equivalent
     458             :     end function
     459             : #endif
     460             : 
     461             : #if SK1_ENABLED
     462             :     function iseq_D1_D1_SK1(segment, pattern) result(equivalent)
     463             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     464             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_SK1
     465             : #endif
     466             :         use pm_kind, only: LK, SKC => SK1
     467             :         character(*,SKC)        , intent(in)    , contiguous    :: segment(:)
     468             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
     469             :         logical(LK)                                             :: equivalent
     470             :     end function
     471             : #endif
     472             : 
     473             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     474             : 
     475             : #if IK5_ENABLED
     476             :     function iseq_D1_D1_IK5(segment, pattern) result(equivalent)
     477             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     478             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_IK5
     479             : #endif
     480             :         use pm_kind, only: LK, IKC => IK5
     481             :         integer(IKC)            , intent(in)    , contiguous    :: segment(:)
     482             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
     483             :         logical(LK)                                             :: equivalent
     484             :     end function
     485             : #endif
     486             : 
     487             : #if IK4_ENABLED
     488             :     function iseq_D1_D1_IK4(segment, pattern) result(equivalent)
     489             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     490             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_IK4
     491             : #endif
     492             :         use pm_kind, only: LK, IKC => IK4
     493             :         integer(IKC)            , intent(in)    , contiguous    :: segment(:)
     494             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
     495             :         logical(LK)                                             :: equivalent
     496             :     end function
     497             : #endif
     498             : 
     499             : #if IK3_ENABLED
     500             :     function iseq_D1_D1_IK3(segment, pattern) result(equivalent)
     501             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     502             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_IK3
     503             : #endif
     504             :         use pm_kind, only: LK, IKC => IK3
     505             :         integer(IKC)            , intent(in)    , contiguous    :: segment(:)
     506             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
     507             :         logical(LK)                                             :: equivalent
     508             :     end function
     509             : #endif
     510             : 
     511             : #if IK2_ENABLED
     512             :     function iseq_D1_D1_IK2(segment, pattern) result(equivalent)
     513             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     514             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_IK2
     515             : #endif
     516             :         use pm_kind, only: LK, IKC => IK2
     517             :         integer(IKC)            , intent(in)    , contiguous    :: segment(:)
     518             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
     519             :         logical(LK)                                             :: equivalent
     520             :     end function
     521             : #endif
     522             : 
     523             : #if IK1_ENABLED
     524             :     function iseq_D1_D1_IK1(segment, pattern) result(equivalent)
     525             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     526             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_IK1
     527             : #endif
     528             :         use pm_kind, only: LK, IKC => IK1
     529             :         integer(IKC)            , intent(in)    , contiguous    :: segment(:)
     530             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
     531             :         logical(LK)                                             :: equivalent
     532             :     end function
     533             : #endif
     534             : 
     535             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     536             : 
     537             : #if LK5_ENABLED
     538             :     function iseq_D1_D1_LK5(segment, pattern) result(equivalent)
     539             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     540             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_LK5
     541             : #endif
     542             :         use pm_kind, only: LK, LKC => LK5
     543             :         logical(LKC)            , intent(in)    , contiguous    :: segment(:)
     544             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
     545             :         logical(LK)                                             :: equivalent
     546             :     end function
     547             : #endif
     548             : 
     549             : #if LK4_ENABLED
     550             :     function iseq_D1_D1_LK4(segment, pattern) result(equivalent)
     551             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     552             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_LK4
     553             : #endif
     554             :         use pm_kind, only: LK, LKC => LK4
     555             :         logical(LKC)            , intent(in)    , contiguous    :: segment(:)
     556             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
     557             :         logical(LK)                                             :: equivalent
     558             :     end function
     559             : #endif
     560             : 
     561             : #if LK3_ENABLED
     562             :     function iseq_D1_D1_LK3(segment, pattern) result(equivalent)
     563             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     564             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_LK3
     565             : #endif
     566             :         use pm_kind, only: LK, LKC => LK3
     567             :         logical(LKC)            , intent(in)    , contiguous    :: segment(:)
     568             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
     569             :         logical(LK)                                             :: equivalent
     570             :     end function
     571             : #endif
     572             : 
     573             : #if LK2_ENABLED
     574             :     function iseq_D1_D1_LK2(segment, pattern) result(equivalent)
     575             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     576             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_LK2
     577             : #endif
     578             :         use pm_kind, only: LK, LKC => LK2
     579             :         logical(LKC)            , intent(in)    , contiguous    :: segment(:)
     580             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
     581             :         logical(LK)                                             :: equivalent
     582             :     end function
     583             : #endif
     584             : 
     585             : #if LK1_ENABLED
     586             :     function iseq_D1_D1_LK1(segment, pattern) result(equivalent)
     587             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     588             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_LK1
     589             : #endif
     590             :         use pm_kind, only: LK, LKC => LK1
     591             :         logical(LKC)            , intent(in)    , contiguous    :: segment(:)
     592             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
     593             :         logical(LK)                                             :: equivalent
     594             :     end function
     595             : #endif
     596             : 
     597             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     598             : 
     599             : #if CK5_ENABLED
     600             :     function iseq_D1_D1_CK5(segment, pattern) result(equivalent)
     601             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     602             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_CK5
     603             : #endif
     604             :         use pm_kind, only: LK, CKC => CK5
     605             :         complex(CKC)            , intent(in)    , contiguous    :: segment(:)
     606             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
     607             :         logical(LK)                                             :: equivalent
     608             :     end function
     609             : #endif
     610             : 
     611             : #if CK4_ENABLED
     612             :     function iseq_D1_D1_CK4(segment, pattern) result(equivalent)
     613             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     614             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_CK4
     615             : #endif
     616             :         use pm_kind, only: LK, CKC => CK4
     617             :         complex(CKC)            , intent(in)    , contiguous    :: segment(:)
     618             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
     619             :         logical(LK)                                             :: equivalent
     620             :     end function
     621             : #endif
     622             : 
     623             : #if CK3_ENABLED
     624             :     function iseq_D1_D1_CK3(segment, pattern) result(equivalent)
     625             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     626             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_CK3
     627             : #endif
     628             :         use pm_kind, only: LK, CKC => CK3
     629             :         complex(CKC)            , intent(in)    , contiguous    :: segment(:)
     630             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
     631             :         logical(LK)                                             :: equivalent
     632             :     end function
     633             : #endif
     634             : 
     635             : #if CK2_ENABLED
     636             :     function iseq_D1_D1_CK2(segment, pattern) result(equivalent)
     637             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     638             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_CK2
     639             : #endif
     640             :         use pm_kind, only: LK, CKC => CK2
     641             :         complex(CKC)            , intent(in)    , contiguous    :: segment(:)
     642             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
     643             :         logical(LK)                                             :: equivalent
     644             :     end function
     645             : #endif
     646             : 
     647             : #if CK1_ENABLED
     648             :     function iseq_D1_D1_CK1(segment, pattern) result(equivalent)
     649             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     650             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_CK1
     651             : #endif
     652             :         use pm_kind, only: LK, CKC => CK1
     653             :         complex(CKC)            , intent(in)    , contiguous    :: segment(:)
     654             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
     655             :         logical(LK)                                             :: equivalent
     656             :     end function
     657             : #endif
     658             : 
     659             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     660             : 
     661             : #if RK5_ENABLED
     662             :     function iseq_D1_D1_RK5(segment, pattern) result(equivalent)
     663             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     664             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_RK5
     665             : #endif
     666             :         use pm_kind, only: LK, RKC => RK5
     667             :         real(RKC)               , intent(in)    , contiguous    :: segment(:)
     668             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
     669             :         logical(LK)                                             :: equivalent
     670             :     end function
     671             : #endif
     672             : 
     673             : #if RK4_ENABLED
     674             :     function iseq_D1_D1_RK4(segment, pattern) result(equivalent)
     675             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     676             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_RK4
     677             : #endif
     678             :         use pm_kind, only: LK, RKC => RK4
     679             :         real(RKC)               , intent(in)    , contiguous    :: segment(:)
     680             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
     681             :         logical(LK)                                             :: equivalent
     682             :     end function
     683             : #endif
     684             : 
     685             : #if RK3_ENABLED
     686             :     function iseq_D1_D1_RK3(segment, pattern) result(equivalent)
     687             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     688             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_RK3
     689             : #endif
     690             :         use pm_kind, only: LK, RKC => RK3
     691             :         real(RKC)               , intent(in)    , contiguous    :: segment(:)
     692             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
     693             :         logical(LK)                                             :: equivalent
     694             :     end function
     695             : #endif
     696             : 
     697             : #if RK2_ENABLED
     698             :     function iseq_D1_D1_RK2(segment, pattern) result(equivalent)
     699             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     700             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_RK2
     701             : #endif
     702             :         use pm_kind, only: LK, RKC => RK2
     703             :         real(RKC)               , intent(in)    , contiguous    :: segment(:)
     704             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
     705             :         logical(LK)                                             :: equivalent
     706             :     end function
     707             : #endif
     708             : 
     709             : #if RK1_ENABLED
     710             :     function iseq_D1_D1_RK1(segment, pattern) result(equivalent)
     711             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
     712             :         !DEC$ ATTRIBUTES DLLEXPORT :: iseq_D1_D1_RK1
     713             : #endif
     714             :         use pm_kind, only: LK, RKC => RK1
     715             :         real(RKC)               , intent(in)    , contiguous    :: segment(:)
     716             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
     717             :         logical(LK)                                             :: equivalent
     718             :     end function
     719             : #endif
     720             : 
     721             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     722             : 
     723             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     724             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     725             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     726             : 
     727             :     end interface
     728             : #endif
     729             :     !>  \endcond excluded
     730             : 
     731             : !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     732             : 
     733             :     !>  \brief
     734             :     !>  Generate and return an `arrayNew` of the same type and kind as the input `array`,
     735             :     !>  in which the requested instances of the input `pattern` have been replaced with the input `replacement`.
     736             :     !>
     737             :     !>  \details
     738             :     !>  If an input vector of `instance` is specified, representing the specific instances of pattern to change,
     739             :     !>  then only those specific instances will be changed.
     740             :     !>
     741             :     !>  \param[in]  array       :   The input `contiguous` array of rank `1` of either <br>
     742             :     !>                              <ul>
     743             :     !>                                  <li>    type `character` of kind \SKALL, or<br>
     744             :     !>                                  <li>    type `logical` of kind \LKALL, or<br>
     745             :     !>                                  <li>    type `integer` of kind \IKALL, or<br>
     746             :     !>                                  <li>    type `complex` of kind \CKALL, or<br>
     747             :     !>                                  <li>    type `real` of kind \RKALL,<br>
     748             :     !>                              </ul>
     749             :     !>                              or
     750             :     !>                              <ul>
     751             :     !>                                  <li>    a scalar `character` of kind \SKALL,<br>
     752             :     !>                              </ul>
     753             :     !>                              within which the specific instances of the input `pattern` must be replaced.<br>
     754             :     !>  \param[in]  pattern     :   The input `contiguous` array of rank `1` of the same type and kind as the input `array`,
     755             :     !>                              containing the pattern whose instances will have to be replaced in the input `array`.<br>
     756             :     !>  \param[in]  replacement :   The input `contiguous` array of rank `1` of the same type and kind as the input `array`,
     757             :     !>                              containing the replacement that will replace in the instances of `pattern` in the input `array`.<br>
     758             :     !>  \param      iseq        :   The `external` user-specified function that takes either two input assumed-length `character` arguments
     759             :     !>                              (if the input `array` is also an assumed-length `character`) or two array-valued **explicit-shape**
     760             :     !>                              arguments of the same type and kind as the input `array`.<br>
     761             :     !>                              It must return a scalar of type `logical` of default kind \LK that is `.true.` if all elements of
     762             :     !>                              the two input arguments are equivalent (e.g., equal) according to the user-defined criterion, otherwise, it is `.false.`.<br>
     763             :     !>                              The the input `array` is array-valued, then the last argument to `iseq` is the length of the input `pattern`.<br>
     764             :     !>                              The following illustrates the generic interface of `iseq` where `pattern` is array-valued,<br>
     765             :     !>                              \code{.F90}
     766             :     !>                                  function iseq(segment, pattern, lenPattern) result(equivalent)
     767             :     !>                                      use pm_kind, only: IK, LK
     768             :     !>                                      integer(IK) , intent(in)    :: lenPattern
     769             :     !>                                      TYPE(KIND)  , intent(in)    :: segment(lenPattern), pattern(lenPattern)
     770             :     !>                                      logical(LK)                 :: equivalent
     771             :     !>                                  end function
     772             :     !>                              \endcode
     773             :     !>                              where `TYPE(KIND)` represents the type and kind of the input argument `array`, which can be one of the following,
     774             :     !>                              \code{.F90}
     775             :     !>                                  character(*, SK), intent(in)    :: segment(lenPattern), pattern(lenPattern)
     776             :     !>                                  integer(IK)     , intent(in)    :: segment(lenPattern), pattern(lenPattern)
     777             :     !>                                  logical(LK)     , intent(in)    :: segment(lenPattern), pattern(lenPattern)
     778             :     !>                                  complex(CK)     , intent(in)    :: segment(lenPattern), pattern(lenPattern)
     779             :     !>                                  real(RK)        , intent(in)    :: segment(lenPattern), pattern(lenPattern)
     780             :     !>                              \endcode
     781             :     !>                              where the kinds `SKC`, `IKC`, `LKC`, `CKC`, `RK`, can refer to any kind type parameter that is supported by the processor.<br>
     782             :     !>                              The following illustrates the generic interface of `iseq` where `pattern` is scalar-valued (**including Fortran scalar strings**),<br>
     783             :     !>                              \code{.F90}
     784             :     !>                                  function iseq(segment, pattern) result(equivalent)
     785             :     !>                                      use pm_kind, only: LK
     786             :     !>                                      TYPE(KIND)  , intent(in)    :: segment, pattern
     787             :     !>                                      logical(LK)                 :: equivalent
     788             :     !>                                  end function
     789             :     !>                              \endcode
     790             :     !>                              where `TYPE(KIND)` represents the type and kind of the input argument `array`, which can be one of the following,
     791             :     !>                              \code{.F90}
     792             :     !>                                  use pm_kind, only: SK, IK, LK, CK, RK
     793             :     !>                                  character(*, SK), intent(in)    :: segment, pattern
     794             :     !>                                  integer(IK)     , intent(in)    :: segment, pattern
     795             :     !>                                  logical(LK)     , intent(in)    :: segment, pattern
     796             :     !>                                  complex(CK)     , intent(in)    :: segment, pattern
     797             :     !>                                  real(RK)        , intent(in)    :: segment, pattern
     798             :     !>                              \endcode
     799             :     !>                              where the kinds `SK`, `IK`, `LK`, `CK`, `RK`, can refer to any kind type parameter that is supported by the processor.<br>
     800             :     !>                              This user-defined equivalence check is extremely useful where an equivalence test other than exact identity is needed,
     801             :     !>                              for example, when the array segments should match the input `pattern` only within a given threshold or,
     802             :     !>                              when the case-sensitivity in character comparisons do not matter.<br>
     803             :     !>                              In such cases, user can define a custom equivalence criterion within the user-defined external function `iseq` to achieve the goal.<br>
     804             :     !>                              (**optional**, the default equivalence operator is `.eqv.` if the input `array` is `logical`, otherwise `==`)
     805             :     !>  \param[in]  instance    :   The input `contiguous` array of rank `1` of type `integer` of default kind \IK,
     806             :     !>                              containing the instances of the input `pattern` in the input `array` that should be replaced with the input `replacement`.<br>
     807             :     !>                              Any element of `instance` that points to an out-of-scope instance of `pattern` in the input `array` will be ignored.<br>
     808             :     !>                              Any element of `instance` that is negatively valued will be counted from end of the input `array`.<br>
     809             :     !>                              For example, `instance = [2,-1]` requests replacing the second instance of `pattern` in `array` from the beginning and
     810             :     !>                              replacing the first instance of `pattern` starting from the end of `array`.<br>
     811             :     !>                              (**optional**, the default value corresponds to replacing all instances of `pattern` with `replacement` in `array`)
     812             :     !>  \param[in]  sorted      :   The input `logical` of default kind \LK indicating whether the elements of the specified input `instance` are all in ascending-order.<br>
     813             :     !>                              This includes the negative elements of `instance` **after** they are translated to the corresponding **positive** instances from
     814             :     !>                              the beginning of the input `array`.<br>Setting `sorted = .true.` will lead to faster runtime of the procedure.<br>
     815             :     !>                              However, the onus will be strictly on the user to ensure all elements of `instance` are in ascending-order.<br>
     816             :     !>                              This is generally not an easy guarantee to make if there are negative elements in `instance`.<br>
     817             :     !>                              Therefore, set `sorted = .true.` **only if** you can guarantee the validity of the condition.<br>
     818             :     !>                              (**optional**, default = `.false.`. It can be present as input argument **only if** the input argument `instance` is present.)
     819             :     !>  \param[in]  unique      :   The input `logical` of default kind \LK indicating whether the elements of the specified input `instance` are all unique.<br>
     820             :     !>                              This includes the negative elements of `instance` **after** they are translated to the corresponding **positive** instances from
     821             :     !>                              the beginning of the input `array`.<br>Setting `unique = .true.` will lead to faster runtime of the procedure.<br>
     822             :     !>                              However, the onus will be strictly on the user to ensure all elements of `instance` are unique.<br>
     823             :     !>                              This is generally not an easy guarantee to make if there are negative elements in `instance`.<br>
     824             :     !>                              Therefore, set `unique = .true.` **only if** you can guarantee the validity of the condition.<br>
     825             :     !>                              (**optional**, default = `.false.`. It can be present as input argument **only if** the input argument `instance` is present.)
     826             :     !>
     827             :     !>  \return
     828             :     !>  `arrayNew`              :   The output `allocatable` array of the same type and kind as the input `array` in which all
     829             :     !>                              requested instances of the input `pattern` have been replaced with the input `replacement`.
     830             :     !>
     831             :     !>  \interface{getReplaced}
     832             :     !>  \code{.F90}
     833             :     !>
     834             :     !>      use pm_arrayReplace, only: getReplaced
     835             :     !>
     836             :     !>      arrayNew = getReplaced(array, pattern, replacement)
     837             :     !>      arrayNew = getReplaced(array, pattern, replacement, iseq)
     838             :     !>      arrayNew = getReplaced(array, pattern, replacement, instance, sorted = sorted, unique = unique)
     839             :     !>      arrayNew = getReplaced(array, pattern, replacement, iseq, instance, sorted = sorted, unique = unique)
     840             :     !>
     841             :     !>  \endcode
     842             :     !>
     843             :     !>  \warnpure
     844             :     !>
     845             :     !>  \warning
     846             :     !>  The procedures under this generic interface are `impure` when the user-specified `external` procedure `iseq` is specified as input argument.<br>
     847             :     !>
     848             :     !>  \warning
     849             :     !>  Note that in Fortran, trailing blanks are ignored in character comparison, that is, `"Fortran" == "Fortran "` yields `.true.`.<br>
     850             :     !>
     851             :     !>  \remark
     852             :     !>  The functions under this generic interface are slightly slower than the [setReplaced](@ref pm_arrayReplace::setReplaced) subroutine implementations.<br>
     853             :     !>  See [pm_arrayReplace](@ref pm_arrayReplace) for the relevant benchmarks.<br>
     854             :     !>
     855             :     !>  \see
     856             :     !>  [setReplaced](@ref pm_arrayReplace::setReplaced)<br>
     857             :     !>  [setInserted](@ref pm_arrayInsert::setInserted)<br>
     858             :     !>  [setRemoved](@ref pm_arrayRemove::setRemoved)<br>
     859             :     !>  [setSplit](@ref pm_arraySplit::setSplit)<br>
     860             :     !>
     861             :     !>  \example{getReplaced}
     862             :     !>  \include{lineno} example/pm_arrayReplace/getReplaced/main.F90
     863             :     !>  \compilef{getReplaced}
     864             :     !>  \output{getReplaced}
     865             :     !>  \include{lineno} example/pm_arrayReplace/getReplaced/main.out.F90
     866             :     !>
     867             :     !>  \test
     868             :     !>  [test_pm_arrayReplace](@ref test_pm_arrayReplace)
     869             :     !>
     870             :     !>  \bug
     871             :     !>  \status \unresolved
     872             :     !>  \source \ifort{2021.2.0}, \gfortran{10, 11}
     873             :     !>  \desc
     874             :     !>  The \ifort{2021.2.0} has a bug for the following interface definition,<br>
     875             :     !>  \code{.F90}
     876             :     !>      character(len(array))   , allocatable   :: arrayNew(:)
     877             :     !>  \endcode
     878             :     !>  leading to an **internal compiler error**.<br>
     879             :     !>  \remedy
     880             :     !>  For now, the remedy seems to be to redefine the interface as,
     881             :     !>  \code{.F90}
     882             :     !>      character(:, SK), allocatable   :: arrayNew(:)
     883             :     !>  \endcode
     884             :     !>  and changing the allocation method accordingly in the implementation to,
     885             :     !>  \code{.F90}
     886             :     !>      allocate(character(len(array, kind = IK)) :: arrayNew(lenArrayNew))
     887             :     !>  \endcode
     888             :     !>  However, this introduces `internal compiler error: Segmentation fault` with gfortran versions 10 and 11.
     889             :     !>  Here is a code snippet to regenerate the bug in Intel ifort (uncomment the commented line to reproduce the gfortran bug),
     890             :     !>  \code{.F90}
     891             :     !>
     892             :     !>      module pm_explicitLenResult
     893             :     !>          implicit none
     894             :     !>          interface
     895             :     !>              pure module function bug(array) result(arrayNew)
     896             :     !>                  character(*, SK), intent(in), contiguous    :: array(:)
     897             :     !>                  character(len(array),SK)    , allocatable   :: arrayNew(:) ! catastrophic internal error with ifort 2021.2. Fine with gfortran 10.3
     898             :     !>                 !character(:, SK)            , allocatable   :: arrayNew(:) ! catastrophic internal error with gfortran 10.3. Fine with ifort 2021.2
     899             :     !>              end function
     900             :     !>          end interface
     901             :     !>      end module pm_explicitLenResult
     902             :     !>
     903             :     !>      submodule (pm_explicitLenResult) routines
     904             :     !>          implicit none
     905             :     !>      contains
     906             :     !>          module procedure bug
     907             :     !>             allocate(arrayNew, source = array)
     908             :     !>          end procedure
     909             :     !>      end submodule routines
     910             :     !>
     911             :     !>      program main
     912             :     !>          use pm_explicitLenResult, only: bug
     913             :     !>          character(2) :: array(3) = ["AA", "BB", "CC"]
     914             :     !>          character(2), allocatable :: arrayNew(:)
     915             :     !>          arrayNew = bug(array)
     916             :     !>      end program main
     917             :     !>
     918             :     !>  \endcode
     919             :     !>  It turns out that both gfortran and Intel do not tolerate the separation of interface from implementation in the above code snippet.
     920             :     !>  If one duplicates the interface in the implementation submodule, then both compilers compile and run the code with no errors.
     921             :     !>  This is the remedy that is currently used in this [getReplaced](@ref pm_arrayReplace::getReplaced) generic interface
     922             :     !>  (interface duplication where the bug exists). Here is a workaround example for the bug in the above code snippet,
     923             :     !>  \code{.F90}
     924             :     !>
     925             :     !>      module pm_explicitLenResult
     926             :     !>          implicit none
     927             :     !>          interface
     928             :     !>              pure module function bug(array) result(arrayNew)
     929             :     !>                  character(*, SK), intent(in), contiguous    :: array(:)
     930             :     !>                  character(len(array))   , allocatable   :: arrayNew(:) ! catastrophic internal error with ifort 2021.2. Fine with gfortran 10.3
     931             :     !>              end function
     932             :     !>          end interface
     933             :     !>      end module pm_explicitLenResult
     934             :     !>
     935             :     !>      submodule (pm_explicitLenResult) routines
     936             :     !>          implicit none
     937             :     !>      contains
     938             :     !>          module procedure bug
     939             :     !>             allocate(arrayNew, source = array)
     940             :     !>          end procedure
     941             :     !>      end submodule routines
     942             :     !>
     943             :     !>      program main
     944             :     !>          use pm_explicitLenResult, only: bug
     945             :     !>          character(2) :: array(3) = ["AA", "BB", "CC"]
     946             :     !>          character(2), allocatable :: arrayNew(:)
     947             :     !>          arrayNew = bug(array)
     948             :     !>      end program main
     949             :     !>
     950             :     !>  \endcode
     951             :     !>
     952             :     !>  \bug
     953             :     !>  \status \unresolved
     954             :     !>  \source \gfortran{10, 11}
     955             :     !>  \desc
     956             :     !>  The \gfortran cannot run examples that use procedure dummy arguments `iseq()` with explicit interface,
     957             :     !>  yielding the following error:<br>
     958             :     !>  \code{.sh}
     959             :     !>      Fortran runtime error: array bound mismatch for dimension 1 of array 'segment' (0/7021782950660276225)
     960             :     !>  \endcode
     961             :     !>  The \ifort{2021.6} can successfully compile and run the examples.<br>
     962             :     !>  \remedy
     963             :     !>  For now, all `iseq()` procedure dummy argument interfaces are kept implicit.<br>
     964             :     !>
     965             :     !>  \todo
     966             :     !>  The internal compiler error with \ifort and \gfortran has to be fixed in the future versions.<br>
     967             :     !>
     968             :     !>  \todo
     969             :     !>  \plow This generic interface can be extended to 2D input objects.<br>
     970             :     !>
     971             :     !>  \todo
     972             :     !>  \phigh 
     973             :     !>  This generic interface can be extended to scalar input `pattern` and `replacement` arguments.<br>
     974             :     !>  Such an extension will likely lead to runtime performance gain for cases where `pattern` and `replacement` are arrays of length `1`.<br>
     975             :     !>  See [pm_arraySplit](@ref pm_arraySplit) for a relevant benchmark about this matter.<br>
     976             :     !>
     977             :     !>  \todo
     978             :     !>  \phigh 
     979             :     !>  A benchmark comparing the performance of [setReplaced](@ref pm_arrayReplace::setReplaced) with and without `sorted, unique`
     980             :     !>  optional input arguments should be added.<br>
     981             :     !>
     982             :     !>  \finmain{getReplaced}
     983             :     !>
     984             :     !>  \author
     985             :     !>  \AmirShahmoradi, September 1, 2017, 12:00 AM, Institute for Computational Engineering and Sciences (ICES), The University of Texas at Austin
     986             :     interface getReplaced
     987             : 
     988             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     989             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     990             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     991             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     992             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     993             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     994             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     995             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     996             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     997             : 
     998             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
     999             : 
    1000             : #if SK5_ENABLED
    1001             :     PURE module function getReplacedDefComDefIns_D0_D0_D0_SK5(array, pattern, replacement) result(arrayNew)
    1002             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1003             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D0_D0_D0_SK5
    1004             : #endif
    1005             :         use pm_kind, only: SKC => SK5
    1006             :         character(*,SKC)        , intent(in)                    :: array
    1007             :         character(*,SKC)        , intent(in)                    :: pattern
    1008             :         character(*,SKC)        , intent(in)                    :: replacement
    1009             :         character(:,SKC)                        , allocatable   :: arrayNew
    1010             :     end function
    1011             : #endif
    1012             : 
    1013             : #if SK4_ENABLED
    1014             :     PURE module function getReplacedDefComDefIns_D0_D0_D0_SK4(array, pattern, replacement) result(arrayNew)
    1015             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1016             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D0_D0_D0_SK4
    1017             : #endif
    1018             :         use pm_kind, only: SKC => SK4
    1019             :         character(*,SKC)        , intent(in)                    :: array
    1020             :         character(*,SKC)        , intent(in)                    :: pattern
    1021             :         character(*,SKC)        , intent(in)                    :: replacement
    1022             :         character(:,SKC)                        , allocatable   :: arrayNew
    1023             :     end function
    1024             : #endif
    1025             : 
    1026             : #if SK3_ENABLED
    1027             :     PURE module function getReplacedDefComDefIns_D0_D0_D0_SK3(array, pattern, replacement) result(arrayNew)
    1028             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1029             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D0_D0_D0_SK3
    1030             : #endif
    1031             :         use pm_kind, only: SKC => SK3
    1032             :         character(*,SKC)        , intent(in)                    :: array
    1033             :         character(*,SKC)        , intent(in)                    :: pattern
    1034             :         character(*,SKC)        , intent(in)                    :: replacement
    1035             :         character(:,SKC)                        , allocatable   :: arrayNew
    1036             :     end function
    1037             : #endif
    1038             : 
    1039             : #if SK2_ENABLED
    1040             :     PURE module function getReplacedDefComDefIns_D0_D0_D0_SK2(array, pattern, replacement) result(arrayNew)
    1041             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1042             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D0_D0_D0_SK2
    1043             : #endif
    1044             :         use pm_kind, only: SKC => SK2
    1045             :         character(*,SKC)        , intent(in)                    :: array
    1046             :         character(*,SKC)        , intent(in)                    :: pattern
    1047             :         character(*,SKC)        , intent(in)                    :: replacement
    1048             :         character(:,SKC)                        , allocatable   :: arrayNew
    1049             :     end function
    1050             : 
    1051             : #endif
    1052             : 
    1053             : #if SK1_ENABLED
    1054             :     PURE module function getReplacedDefComDefIns_D0_D0_D0_SK1(array, pattern, replacement) result(arrayNew)
    1055             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1056             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D0_D0_D0_SK1
    1057             : #endif
    1058             :         use pm_kind, only: SKC => SK1
    1059             :         character(*,SKC)        , intent(in)                    :: array
    1060             :         character(*,SKC)        , intent(in)                    :: pattern
    1061             :         character(*,SKC)        , intent(in)                    :: replacement
    1062             :         character(:,SKC)                        , allocatable   :: arrayNew
    1063             :     end function
    1064             : #endif
    1065             : 
    1066             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1067             : 
    1068             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1069             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1070             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1071             : 
    1072             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1073             : 
    1074             : #if SK5_ENABLED
    1075             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_SK5(array, pattern, replacement) result(arrayNew)
    1076             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1077             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_SK5
    1078             : #endif
    1079             :         use pm_kind, only: SKC => SK5
    1080             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1081             :         character(*,SKC)        , intent(in)                    :: pattern
    1082             :         character(*,SKC)        , intent(in)                    :: replacement
    1083             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1084             :     end function
    1085             : #endif
    1086             : 
    1087             : #if SK4_ENABLED
    1088             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_SK4(array, pattern, replacement) result(arrayNew)
    1089             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1090             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_SK4
    1091             : #endif
    1092             :         use pm_kind, only: SKC => SK4
    1093             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1094             :         character(*,SKC)        , intent(in)                    :: pattern
    1095             :         character(*,SKC)        , intent(in)                    :: replacement
    1096             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1097             :     end function
    1098             : #endif
    1099             : 
    1100             : #if SK3_ENABLED
    1101             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_SK3(array, pattern, replacement) result(arrayNew)
    1102             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1103             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_SK3
    1104             : #endif
    1105             :         use pm_kind, only: SKC => SK3
    1106             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1107             :         character(*,SKC)        , intent(in)                    :: pattern
    1108             :         character(*,SKC)        , intent(in)                    :: replacement
    1109             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1110             :     end function
    1111             : #endif
    1112             : 
    1113             : #if SK2_ENABLED
    1114             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_SK2(array, pattern, replacement) result(arrayNew)
    1115             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1116             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_SK2
    1117             : #endif
    1118             :         use pm_kind, only: SKC => SK2
    1119             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1120             :         character(*,SKC)        , intent(in)                    :: pattern
    1121             :         character(*,SKC)        , intent(in)                    :: replacement
    1122             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1123             :     end function
    1124             : 
    1125             : #endif
    1126             : 
    1127             : #if SK1_ENABLED
    1128             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_SK1(array, pattern, replacement) result(arrayNew)
    1129             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1130             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_SK1
    1131             : #endif
    1132             :         use pm_kind, only: SKC => SK1
    1133             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1134             :         character(*,SKC)        , intent(in)                    :: pattern
    1135             :         character(*,SKC)        , intent(in)                    :: replacement
    1136             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1137             :     end function
    1138             : #endif
    1139             : 
    1140             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1141             : 
    1142             : #if IK5_ENABLED
    1143             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_IK5(array, pattern, replacement) result(arrayNew)
    1144             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1145             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_IK5
    1146             : #endif
    1147             :         use pm_kind, only: IKC => IK5
    1148             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1149             :         integer(IKC)            , intent(in)                    :: pattern
    1150             :         integer(IKC)            , intent(in)                    :: replacement
    1151             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1152             :     end function
    1153             : #endif
    1154             : 
    1155             : #if IK4_ENABLED
    1156             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_IK4(array, pattern, replacement) result(arrayNew)
    1157             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1158             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_IK4
    1159             : #endif
    1160             :         use pm_kind, only: IKC => IK4
    1161             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1162             :         integer(IKC)            , intent(in)                    :: pattern
    1163             :         integer(IKC)            , intent(in)                    :: replacement
    1164             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1165             :     end function
    1166             : #endif
    1167             : 
    1168             : #if IK3_ENABLED
    1169             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_IK3(array, pattern, replacement) result(arrayNew)
    1170             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1171             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_IK3
    1172             : #endif
    1173             :         use pm_kind, only: IKC => IK3
    1174             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1175             :         integer(IKC)            , intent(in)                    :: pattern
    1176             :         integer(IKC)            , intent(in)                    :: replacement
    1177             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1178             :     end function
    1179             : #endif
    1180             : 
    1181             : #if IK2_ENABLED
    1182             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_IK2(array, pattern, replacement) result(arrayNew)
    1183             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1184             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_IK2
    1185             : #endif
    1186             :         use pm_kind, only: IKC => IK2
    1187             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1188             :         integer(IKC)            , intent(in)                    :: pattern
    1189             :         integer(IKC)            , intent(in)                    :: replacement
    1190             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1191             :     end function
    1192             : 
    1193             : #endif
    1194             : 
    1195             : #if IK1_ENABLED
    1196             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_IK1(array, pattern, replacement) result(arrayNew)
    1197             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1198             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_IK1
    1199             : #endif
    1200             :         use pm_kind, only: IKC => IK1
    1201             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1202             :         integer(IKC)            , intent(in)                    :: pattern
    1203             :         integer(IKC)            , intent(in)                    :: replacement
    1204             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1205             :     end function
    1206             : #endif
    1207             : 
    1208             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1209             : 
    1210             : #if LK5_ENABLED
    1211             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_LK5(array, pattern, replacement) result(arrayNew)
    1212             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1213             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_LK5
    1214             : #endif
    1215             :         use pm_kind, only: LKC => LK5
    1216             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1217             :         logical(LKC)            , intent(in)                    :: pattern
    1218             :         logical(LKC)            , intent(in)                    :: replacement
    1219             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1220             :     end function
    1221             : #endif
    1222             : 
    1223             : #if LK4_ENABLED
    1224             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_LK4(array, pattern, replacement) result(arrayNew)
    1225             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1226             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_LK4
    1227             : #endif
    1228             :         use pm_kind, only: LKC => LK4
    1229             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1230             :         logical(LKC)            , intent(in)                    :: pattern
    1231             :         logical(LKC)            , intent(in)                    :: replacement
    1232             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1233             :     end function
    1234             : #endif
    1235             : 
    1236             : #if LK3_ENABLED
    1237             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_LK3(array, pattern, replacement) result(arrayNew)
    1238             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1239             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_LK3
    1240             : #endif
    1241             :         use pm_kind, only: LKC => LK3
    1242             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1243             :         logical(LKC)            , intent(in)                    :: pattern
    1244             :         logical(LKC)            , intent(in)                    :: replacement
    1245             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1246             :     end function
    1247             : #endif
    1248             : 
    1249             : #if LK2_ENABLED
    1250             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_LK2(array, pattern, replacement) result(arrayNew)
    1251             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1252             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_LK2
    1253             : #endif
    1254             :         use pm_kind, only: LKC => LK2
    1255             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1256             :         logical(LKC)            , intent(in)                    :: pattern
    1257             :         logical(LKC)            , intent(in)                    :: replacement
    1258             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1259             :     end function
    1260             : 
    1261             : #endif
    1262             : 
    1263             : #if LK1_ENABLED
    1264             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_LK1(array, pattern, replacement) result(arrayNew)
    1265             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1266             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_LK1
    1267             : #endif
    1268             :         use pm_kind, only: LKC => LK1
    1269             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1270             :         logical(LKC)            , intent(in)                    :: pattern
    1271             :         logical(LKC)            , intent(in)                    :: replacement
    1272             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1273             :     end function
    1274             : #endif
    1275             : 
    1276             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1277             : 
    1278             : #if CK5_ENABLED
    1279             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_CK5(array, pattern, replacement) result(arrayNew)
    1280             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1281             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_CK5
    1282             : #endif
    1283             :         use pm_kind, only: CKC => CK5
    1284             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1285             :         complex(CKC)            , intent(in)                    :: pattern
    1286             :         complex(CKC)            , intent(in)                    :: replacement
    1287             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1288             :     end function
    1289             : #endif
    1290             : 
    1291             : #if CK4_ENABLED
    1292             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_CK4(array, pattern, replacement) result(arrayNew)
    1293             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1294             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_CK4
    1295             : #endif
    1296             :         use pm_kind, only: CKC => CK4
    1297             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1298             :         complex(CKC)            , intent(in)                    :: pattern
    1299             :         complex(CKC)            , intent(in)                    :: replacement
    1300             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1301             :     end function
    1302             : #endif
    1303             : 
    1304             : #if CK3_ENABLED
    1305             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_CK3(array, pattern, replacement) result(arrayNew)
    1306             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1307             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_CK3
    1308             : #endif
    1309             :         use pm_kind, only: CKC => CK3
    1310             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1311             :         complex(CKC)            , intent(in)                    :: pattern
    1312             :         complex(CKC)            , intent(in)                    :: replacement
    1313             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1314             :     end function
    1315             : #endif
    1316             : 
    1317             : #if CK2_ENABLED
    1318             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_CK2(array, pattern, replacement) result(arrayNew)
    1319             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1320             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_CK2
    1321             : #endif
    1322             :         use pm_kind, only: CKC => CK2
    1323             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1324             :         complex(CKC)            , intent(in)                    :: pattern
    1325             :         complex(CKC)            , intent(in)                    :: replacement
    1326             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1327             :     end function
    1328             : 
    1329             : #endif
    1330             : 
    1331             : #if CK1_ENABLED
    1332             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_CK1(array, pattern, replacement) result(arrayNew)
    1333             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1334             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_CK1
    1335             : #endif
    1336             :         use pm_kind, only: CKC => CK1
    1337             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1338             :         complex(CKC)            , intent(in)                    :: pattern
    1339             :         complex(CKC)            , intent(in)                    :: replacement
    1340             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1341             :     end function
    1342             : #endif
    1343             : 
    1344             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1345             : 
    1346             : #if RK5_ENABLED
    1347             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_RK5(array, pattern, replacement) result(arrayNew)
    1348             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1349             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_RK5
    1350             : #endif
    1351             :         use pm_kind, only: RKC => RK5
    1352             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    1353             :         real(RKC)               , intent(in)                    :: pattern
    1354             :         real(RKC)               , intent(in)                    :: replacement
    1355             :         real(RKC)                               , allocatable   :: arrayNew(:)
    1356             :     end function
    1357             : #endif
    1358             : 
    1359             : #if RK4_ENABLED
    1360             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_RK4(array, pattern, replacement) result(arrayNew)
    1361             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1362             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_RK4
    1363             : #endif
    1364             :         use pm_kind, only: RKC => RK4
    1365             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    1366             :         real(RKC)               , intent(in)                    :: pattern
    1367             :         real(RKC)               , intent(in)                    :: replacement
    1368             :         real(RKC)                               , allocatable   :: arrayNew(:)
    1369             :     end function
    1370             : #endif
    1371             : 
    1372             : #if RK3_ENABLED
    1373             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_RK3(array, pattern, replacement) result(arrayNew)
    1374             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1375             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_RK3
    1376             : #endif
    1377             :         use pm_kind, only: RKC => RK3
    1378             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    1379             :         real(RKC)               , intent(in)                    :: pattern
    1380             :         real(RKC)               , intent(in)                    :: replacement
    1381             :         real(RKC)                               , allocatable   :: arrayNew(:)
    1382             :     end function
    1383             : #endif
    1384             : 
    1385             : #if RK2_ENABLED
    1386             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_RK2(array, pattern, replacement) result(arrayNew)
    1387             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1388             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_RK2
    1389             : #endif
    1390             :         use pm_kind, only: RKC => RK2
    1391             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    1392             :         real(RKC)               , intent(in)                    :: pattern
    1393             :         real(RKC)               , intent(in)                    :: replacement
    1394             :         real(RKC)                               , allocatable   :: arrayNew(:)
    1395             :     end function
    1396             : 
    1397             : #endif
    1398             : 
    1399             : #if RK1_ENABLED
    1400             :     PURE module function getReplacedDefComDefIns_D1_D0_D0_RK1(array, pattern, replacement) result(arrayNew)
    1401             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1402             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D0_RK1
    1403             : #endif
    1404             :         use pm_kind, only: RKC => RK1
    1405             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    1406             :         real(RKC)               , intent(in)                    :: pattern
    1407             :         real(RKC)               , intent(in)                    :: replacement
    1408             :         real(RKC)                               , allocatable   :: arrayNew(:)
    1409             :     end function
    1410             : #endif
    1411             : 
    1412             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1413             : 
    1414             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1415             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1416             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1417             : 
    1418             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1419             : 
    1420             : #if SK5_ENABLED
    1421             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_SK5(array, pattern, replacement) result(arrayNew)
    1422             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1423             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_SK5
    1424             : #endif
    1425             :         use pm_kind, only: SKC => SK5
    1426             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1427             :         character(*,SKC)        , intent(in)                    :: pattern
    1428             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    1429             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1430             :     end function
    1431             : #endif
    1432             : 
    1433             : #if SK4_ENABLED
    1434             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_SK4(array, pattern, replacement) result(arrayNew)
    1435             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1436             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_SK4
    1437             : #endif
    1438             :         use pm_kind, only: SKC => SK4
    1439             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1440             :         character(*,SKC)        , intent(in)                    :: pattern
    1441             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    1442             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1443             :     end function
    1444             : #endif
    1445             : 
    1446             : #if SK3_ENABLED
    1447             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_SK3(array, pattern, replacement) result(arrayNew)
    1448             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1449             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_SK3
    1450             : #endif
    1451             :         use pm_kind, only: SKC => SK3
    1452             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1453             :         character(*,SKC)        , intent(in)                    :: pattern
    1454             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    1455             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1456             :     end function
    1457             : #endif
    1458             : 
    1459             : #if SK2_ENABLED
    1460             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_SK2(array, pattern, replacement) result(arrayNew)
    1461             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1462             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_SK2
    1463             : #endif
    1464             :         use pm_kind, only: SKC => SK2
    1465             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1466             :         character(*,SKC)        , intent(in)                    :: pattern
    1467             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    1468             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1469             :     end function
    1470             : 
    1471             : #endif
    1472             : 
    1473             : #if SK1_ENABLED
    1474             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_SK1(array, pattern, replacement) result(arrayNew)
    1475             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1476             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_SK1
    1477             : #endif
    1478             :         use pm_kind, only: SKC => SK1
    1479             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1480             :         character(*,SKC)        , intent(in)                    :: pattern
    1481             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    1482             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1483             :     end function
    1484             : #endif
    1485             : 
    1486             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1487             : 
    1488             : #if IK5_ENABLED
    1489             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_IK5(array, pattern, replacement) result(arrayNew)
    1490             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1491             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_IK5
    1492             : #endif
    1493             :         use pm_kind, only: IKC => IK5
    1494             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1495             :         integer(IKC)            , intent(in)                    :: pattern
    1496             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    1497             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1498             :     end function
    1499             : #endif
    1500             : 
    1501             : #if IK4_ENABLED
    1502             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_IK4(array, pattern, replacement) result(arrayNew)
    1503             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1504             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_IK4
    1505             : #endif
    1506             :         use pm_kind, only: IKC => IK4
    1507             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1508             :         integer(IKC)            , intent(in)                    :: pattern
    1509             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    1510             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1511             :     end function
    1512             : #endif
    1513             : 
    1514             : #if IK3_ENABLED
    1515             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_IK3(array, pattern, replacement) result(arrayNew)
    1516             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1517             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_IK3
    1518             : #endif
    1519             :         use pm_kind, only: IKC => IK3
    1520             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1521             :         integer(IKC)            , intent(in)                    :: pattern
    1522             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    1523             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1524             :     end function
    1525             : #endif
    1526             : 
    1527             : #if IK2_ENABLED
    1528             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_IK2(array, pattern, replacement) result(arrayNew)
    1529             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1530             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_IK2
    1531             : #endif
    1532             :         use pm_kind, only: IKC => IK2
    1533             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1534             :         integer(IKC)            , intent(in)                    :: pattern
    1535             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    1536             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1537             :     end function
    1538             : 
    1539             : #endif
    1540             : 
    1541             : #if IK1_ENABLED
    1542             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_IK1(array, pattern, replacement) result(arrayNew)
    1543             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1544             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_IK1
    1545             : #endif
    1546             :         use pm_kind, only: IKC => IK1
    1547             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1548             :         integer(IKC)            , intent(in)                    :: pattern
    1549             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    1550             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1551             :     end function
    1552             : #endif
    1553             : 
    1554             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1555             : 
    1556             : #if LK5_ENABLED
    1557             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_LK5(array, pattern, replacement) result(arrayNew)
    1558             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1559             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_LK5
    1560             : #endif
    1561             :         use pm_kind, only: LKC => LK5
    1562             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1563             :         logical(LKC)            , intent(in)                    :: pattern
    1564             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    1565             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1566             :     end function
    1567             : #endif
    1568             : 
    1569             : #if LK4_ENABLED
    1570             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_LK4(array, pattern, replacement) result(arrayNew)
    1571             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1572             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_LK4
    1573             : #endif
    1574             :         use pm_kind, only: LKC => LK4
    1575             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1576             :         logical(LKC)            , intent(in)                    :: pattern
    1577             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    1578             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1579             :     end function
    1580             : #endif
    1581             : 
    1582             : #if LK3_ENABLED
    1583             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_LK3(array, pattern, replacement) result(arrayNew)
    1584             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1585             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_LK3
    1586             : #endif
    1587             :         use pm_kind, only: LKC => LK3
    1588             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1589             :         logical(LKC)            , intent(in)                    :: pattern
    1590             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    1591             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1592             :     end function
    1593             : #endif
    1594             : 
    1595             : #if LK2_ENABLED
    1596             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_LK2(array, pattern, replacement) result(arrayNew)
    1597             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1598             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_LK2
    1599             : #endif
    1600             :         use pm_kind, only: LKC => LK2
    1601             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1602             :         logical(LKC)            , intent(in)                    :: pattern
    1603             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    1604             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1605             :     end function
    1606             : 
    1607             : #endif
    1608             : 
    1609             : #if LK1_ENABLED
    1610             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_LK1(array, pattern, replacement) result(arrayNew)
    1611             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1612             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_LK1
    1613             : #endif
    1614             :         use pm_kind, only: LKC => LK1
    1615             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1616             :         logical(LKC)            , intent(in)                    :: pattern
    1617             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    1618             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1619             :     end function
    1620             : #endif
    1621             : 
    1622             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1623             : 
    1624             : #if CK5_ENABLED
    1625             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_CK5(array, pattern, replacement) result(arrayNew)
    1626             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1627             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_CK5
    1628             : #endif
    1629             :         use pm_kind, only: CKC => CK5
    1630             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1631             :         complex(CKC)            , intent(in)                    :: pattern
    1632             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    1633             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1634             :     end function
    1635             : #endif
    1636             : 
    1637             : #if CK4_ENABLED
    1638             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_CK4(array, pattern, replacement) result(arrayNew)
    1639             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1640             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_CK4
    1641             : #endif
    1642             :         use pm_kind, only: CKC => CK4
    1643             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1644             :         complex(CKC)            , intent(in)                    :: pattern
    1645             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    1646             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1647             :     end function
    1648             : #endif
    1649             : 
    1650             : #if CK3_ENABLED
    1651             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_CK3(array, pattern, replacement) result(arrayNew)
    1652             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1653             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_CK3
    1654             : #endif
    1655             :         use pm_kind, only: CKC => CK3
    1656             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1657             :         complex(CKC)            , intent(in)                    :: pattern
    1658             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    1659             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1660             :     end function
    1661             : #endif
    1662             : 
    1663             : #if CK2_ENABLED
    1664             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_CK2(array, pattern, replacement) result(arrayNew)
    1665             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1666             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_CK2
    1667             : #endif
    1668             :         use pm_kind, only: CKC => CK2
    1669             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1670             :         complex(CKC)            , intent(in)                    :: pattern
    1671             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    1672             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1673             :     end function
    1674             : 
    1675             : #endif
    1676             : 
    1677             : #if CK1_ENABLED
    1678             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_CK1(array, pattern, replacement) result(arrayNew)
    1679             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1680             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_CK1
    1681             : #endif
    1682             :         use pm_kind, only: CKC => CK1
    1683             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1684             :         complex(CKC)            , intent(in)                    :: pattern
    1685             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    1686             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1687             :     end function
    1688             : #endif
    1689             : 
    1690             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1691             : 
    1692             : #if RK5_ENABLED
    1693             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_RK5(array, pattern, replacement) result(arrayNew)
    1694             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1695             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_RK5
    1696             : #endif
    1697             :         use pm_kind, only: RKC => RK5
    1698             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    1699             :         real(RKC)               , intent(in)                    :: pattern
    1700             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    1701             :         real(RKC)                               , allocatable   :: arrayNew(:)
    1702             :     end function
    1703             : #endif
    1704             : 
    1705             : #if RK4_ENABLED
    1706             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_RK4(array, pattern, replacement) result(arrayNew)
    1707             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1708             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_RK4
    1709             : #endif
    1710             :         use pm_kind, only: RKC => RK4
    1711             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    1712             :         real(RKC)               , intent(in)                    :: pattern
    1713             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    1714             :         real(RKC)                               , allocatable   :: arrayNew(:)
    1715             :     end function
    1716             : #endif
    1717             : 
    1718             : #if RK3_ENABLED
    1719             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_RK3(array, pattern, replacement) result(arrayNew)
    1720             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1721             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_RK3
    1722             : #endif
    1723             :         use pm_kind, only: RKC => RK3
    1724             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    1725             :         real(RKC)               , intent(in)                    :: pattern
    1726             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    1727             :         real(RKC)                               , allocatable   :: arrayNew(:)
    1728             :     end function
    1729             : #endif
    1730             : 
    1731             : #if RK2_ENABLED
    1732             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_RK2(array, pattern, replacement) result(arrayNew)
    1733             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1734             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_RK2
    1735             : #endif
    1736             :         use pm_kind, only: RKC => RK2
    1737             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    1738             :         real(RKC)               , intent(in)                    :: pattern
    1739             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    1740             :         real(RKC)                               , allocatable   :: arrayNew(:)
    1741             :     end function
    1742             : 
    1743             : #endif
    1744             : 
    1745             : #if RK1_ENABLED
    1746             :     PURE module function getReplacedDefComDefIns_D1_D0_D1_RK1(array, pattern, replacement) result(arrayNew)
    1747             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1748             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D0_D1_RK1
    1749             : #endif
    1750             :         use pm_kind, only: RKC => RK1
    1751             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    1752             :         real(RKC)               , intent(in)                    :: pattern
    1753             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    1754             :         real(RKC)                               , allocatable   :: arrayNew(:)
    1755             :     end function
    1756             : #endif
    1757             : 
    1758             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1759             : 
    1760             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1761             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1762             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1763             : 
    1764             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1765             : 
    1766             : #if SK5_ENABLED
    1767             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_SK5(array, pattern, replacement) result(arrayNew)
    1768             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1769             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_SK5
    1770             : #endif
    1771             :         use pm_kind, only: SKC => SK5
    1772             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1773             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    1774             :         character(*,SKC)        , intent(in)                    :: replacement
    1775             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1776             :     end function
    1777             : #endif
    1778             : 
    1779             : #if SK4_ENABLED
    1780             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_SK4(array, pattern, replacement) result(arrayNew)
    1781             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1782             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_SK4
    1783             : #endif
    1784             :         use pm_kind, only: SKC => SK4
    1785             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1786             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    1787             :         character(*,SKC)        , intent(in)                    :: replacement
    1788             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1789             :     end function
    1790             : #endif
    1791             : 
    1792             : #if SK3_ENABLED
    1793             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_SK3(array, pattern, replacement) result(arrayNew)
    1794             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1795             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_SK3
    1796             : #endif
    1797             :         use pm_kind, only: SKC => SK3
    1798             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1799             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    1800             :         character(*,SKC)        , intent(in)                    :: replacement
    1801             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1802             :     end function
    1803             : #endif
    1804             : 
    1805             : #if SK2_ENABLED
    1806             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_SK2(array, pattern, replacement) result(arrayNew)
    1807             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1808             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_SK2
    1809             : #endif
    1810             :         use pm_kind, only: SKC => SK2
    1811             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1812             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    1813             :         character(*,SKC)        , intent(in)                    :: replacement
    1814             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1815             :     end function
    1816             : 
    1817             : #endif
    1818             : 
    1819             : #if SK1_ENABLED
    1820             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_SK1(array, pattern, replacement) result(arrayNew)
    1821             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1822             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_SK1
    1823             : #endif
    1824             :         use pm_kind, only: SKC => SK1
    1825             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    1826             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    1827             :         character(*,SKC)        , intent(in)                    :: replacement
    1828             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    1829             :     end function
    1830             : #endif
    1831             : 
    1832             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1833             : 
    1834             : #if IK5_ENABLED
    1835             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_IK5(array, pattern, replacement) result(arrayNew)
    1836             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1837             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_IK5
    1838             : #endif
    1839             :         use pm_kind, only: IKC => IK5
    1840             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1841             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    1842             :         integer(IKC)            , intent(in)                    :: replacement
    1843             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1844             :     end function
    1845             : #endif
    1846             : 
    1847             : #if IK4_ENABLED
    1848             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_IK4(array, pattern, replacement) result(arrayNew)
    1849             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1850             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_IK4
    1851             : #endif
    1852             :         use pm_kind, only: IKC => IK4
    1853             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1854             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    1855             :         integer(IKC)            , intent(in)                    :: replacement
    1856             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1857             :     end function
    1858             : #endif
    1859             : 
    1860             : #if IK3_ENABLED
    1861             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_IK3(array, pattern, replacement) result(arrayNew)
    1862             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1863             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_IK3
    1864             : #endif
    1865             :         use pm_kind, only: IKC => IK3
    1866             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1867             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    1868             :         integer(IKC)            , intent(in)                    :: replacement
    1869             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1870             :     end function
    1871             : #endif
    1872             : 
    1873             : #if IK2_ENABLED
    1874             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_IK2(array, pattern, replacement) result(arrayNew)
    1875             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1876             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_IK2
    1877             : #endif
    1878             :         use pm_kind, only: IKC => IK2
    1879             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1880             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    1881             :         integer(IKC)            , intent(in)                    :: replacement
    1882             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1883             :     end function
    1884             : 
    1885             : #endif
    1886             : 
    1887             : #if IK1_ENABLED
    1888             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_IK1(array, pattern, replacement) result(arrayNew)
    1889             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1890             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_IK1
    1891             : #endif
    1892             :         use pm_kind, only: IKC => IK1
    1893             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    1894             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    1895             :         integer(IKC)            , intent(in)                    :: replacement
    1896             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    1897             :     end function
    1898             : #endif
    1899             : 
    1900             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1901             : 
    1902             : #if LK5_ENABLED
    1903             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_LK5(array, pattern, replacement) result(arrayNew)
    1904             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1905             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_LK5
    1906             : #endif
    1907             :         use pm_kind, only: LKC => LK5
    1908             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1909             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    1910             :         logical(LKC)            , intent(in)                    :: replacement
    1911             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1912             :     end function
    1913             : #endif
    1914             : 
    1915             : #if LK4_ENABLED
    1916             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_LK4(array, pattern, replacement) result(arrayNew)
    1917             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1918             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_LK4
    1919             : #endif
    1920             :         use pm_kind, only: LKC => LK4
    1921             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1922             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    1923             :         logical(LKC)            , intent(in)                    :: replacement
    1924             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1925             :     end function
    1926             : #endif
    1927             : 
    1928             : #if LK3_ENABLED
    1929             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_LK3(array, pattern, replacement) result(arrayNew)
    1930             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1931             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_LK3
    1932             : #endif
    1933             :         use pm_kind, only: LKC => LK3
    1934             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1935             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    1936             :         logical(LKC)            , intent(in)                    :: replacement
    1937             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1938             :     end function
    1939             : #endif
    1940             : 
    1941             : #if LK2_ENABLED
    1942             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_LK2(array, pattern, replacement) result(arrayNew)
    1943             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1944             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_LK2
    1945             : #endif
    1946             :         use pm_kind, only: LKC => LK2
    1947             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1948             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    1949             :         logical(LKC)            , intent(in)                    :: replacement
    1950             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1951             :     end function
    1952             : 
    1953             : #endif
    1954             : 
    1955             : #if LK1_ENABLED
    1956             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_LK1(array, pattern, replacement) result(arrayNew)
    1957             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1958             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_LK1
    1959             : #endif
    1960             :         use pm_kind, only: LKC => LK1
    1961             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    1962             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    1963             :         logical(LKC)            , intent(in)                    :: replacement
    1964             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    1965             :     end function
    1966             : #endif
    1967             : 
    1968             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    1969             : 
    1970             : #if CK5_ENABLED
    1971             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_CK5(array, pattern, replacement) result(arrayNew)
    1972             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1973             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_CK5
    1974             : #endif
    1975             :         use pm_kind, only: CKC => CK5
    1976             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1977             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    1978             :         complex(CKC)            , intent(in)                    :: replacement
    1979             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1980             :     end function
    1981             : #endif
    1982             : 
    1983             : #if CK4_ENABLED
    1984             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_CK4(array, pattern, replacement) result(arrayNew)
    1985             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1986             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_CK4
    1987             : #endif
    1988             :         use pm_kind, only: CKC => CK4
    1989             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    1990             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    1991             :         complex(CKC)            , intent(in)                    :: replacement
    1992             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    1993             :     end function
    1994             : #endif
    1995             : 
    1996             : #if CK3_ENABLED
    1997             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_CK3(array, pattern, replacement) result(arrayNew)
    1998             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    1999             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_CK3
    2000             : #endif
    2001             :         use pm_kind, only: CKC => CK3
    2002             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2003             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    2004             :         complex(CKC)            , intent(in)                    :: replacement
    2005             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2006             :     end function
    2007             : #endif
    2008             : 
    2009             : #if CK2_ENABLED
    2010             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_CK2(array, pattern, replacement) result(arrayNew)
    2011             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2012             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_CK2
    2013             : #endif
    2014             :         use pm_kind, only: CKC => CK2
    2015             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2016             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    2017             :         complex(CKC)            , intent(in)                    :: replacement
    2018             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2019             :     end function
    2020             : 
    2021             : #endif
    2022             : 
    2023             : #if CK1_ENABLED
    2024             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_CK1(array, pattern, replacement) result(arrayNew)
    2025             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2026             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_CK1
    2027             : #endif
    2028             :         use pm_kind, only: CKC => CK1
    2029             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2030             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    2031             :         complex(CKC)            , intent(in)                    :: replacement
    2032             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2033             :     end function
    2034             : #endif
    2035             : 
    2036             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2037             : 
    2038             : #if RK5_ENABLED
    2039             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_RK5(array, pattern, replacement) result(arrayNew)
    2040             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2041             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_RK5
    2042             : #endif
    2043             :         use pm_kind, only: RKC => RK5
    2044             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2045             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    2046             :         real(RKC)               , intent(in)                    :: replacement
    2047             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2048             :     end function
    2049             : #endif
    2050             : 
    2051             : #if RK4_ENABLED
    2052             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_RK4(array, pattern, replacement) result(arrayNew)
    2053             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2054             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_RK4
    2055             : #endif
    2056             :         use pm_kind, only: RKC => RK4
    2057             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2058             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    2059             :         real(RKC)               , intent(in)                    :: replacement
    2060             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2061             :     end function
    2062             : #endif
    2063             : 
    2064             : #if RK3_ENABLED
    2065             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_RK3(array, pattern, replacement) result(arrayNew)
    2066             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2067             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_RK3
    2068             : #endif
    2069             :         use pm_kind, only: RKC => RK3
    2070             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2071             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    2072             :         real(RKC)               , intent(in)                    :: replacement
    2073             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2074             :     end function
    2075             : #endif
    2076             : 
    2077             : #if RK2_ENABLED
    2078             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_RK2(array, pattern, replacement) result(arrayNew)
    2079             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2080             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_RK2
    2081             : #endif
    2082             :         use pm_kind, only: RKC => RK2
    2083             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2084             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    2085             :         real(RKC)               , intent(in)                    :: replacement
    2086             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2087             :     end function
    2088             : 
    2089             : #endif
    2090             : 
    2091             : #if RK1_ENABLED
    2092             :     PURE module function getReplacedDefComDefIns_D1_D1_D0_RK1(array, pattern, replacement) result(arrayNew)
    2093             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2094             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D0_RK1
    2095             : #endif
    2096             :         use pm_kind, only: RKC => RK1
    2097             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2098             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    2099             :         real(RKC)               , intent(in)                    :: replacement
    2100             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2101             :     end function
    2102             : #endif
    2103             : 
    2104             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2105             : 
    2106             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2107             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2108             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2109             : 
    2110             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2111             : 
    2112             : #if SK5_ENABLED
    2113             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_SK5(array, pattern, replacement) result(arrayNew)
    2114             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2115             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_SK5
    2116             : #endif
    2117             :         use pm_kind, only: SKC => SK5
    2118             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2119             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    2120             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    2121             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2122             :     end function
    2123             : #endif
    2124             : 
    2125             : #if SK4_ENABLED
    2126             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_SK4(array, pattern, replacement) result(arrayNew)
    2127             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2128             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_SK4
    2129             : #endif
    2130             :         use pm_kind, only: SKC => SK4
    2131             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2132             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    2133             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    2134             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2135             :     end function
    2136             : #endif
    2137             : 
    2138             : #if SK3_ENABLED
    2139             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_SK3(array, pattern, replacement) result(arrayNew)
    2140             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2141             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_SK3
    2142             : #endif
    2143             :         use pm_kind, only: SKC => SK3
    2144             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2145             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    2146             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    2147             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2148             :     end function
    2149             : #endif
    2150             : 
    2151             : #if SK2_ENABLED
    2152             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_SK2(array, pattern, replacement) result(arrayNew)
    2153             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2154             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_SK2
    2155             : #endif
    2156             :         use pm_kind, only: SKC => SK2
    2157             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2158             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    2159             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    2160             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2161             :     end function
    2162             : 
    2163             : #endif
    2164             : 
    2165             : #if SK1_ENABLED
    2166             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_SK1(array, pattern, replacement) result(arrayNew)
    2167             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2168             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_SK1
    2169             : #endif
    2170             :         use pm_kind, only: SKC => SK1
    2171             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2172             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    2173             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    2174             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2175             :     end function
    2176             : #endif
    2177             : 
    2178             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2179             : 
    2180             : #if IK5_ENABLED
    2181             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_IK5(array, pattern, replacement) result(arrayNew)
    2182             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2183             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_IK5
    2184             : #endif
    2185             :         use pm_kind, only: IKC => IK5
    2186             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    2187             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    2188             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    2189             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    2190             :     end function
    2191             : #endif
    2192             : 
    2193             : #if IK4_ENABLED
    2194             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_IK4(array, pattern, replacement) result(arrayNew)
    2195             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2196             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_IK4
    2197             : #endif
    2198             :         use pm_kind, only: IKC => IK4
    2199             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    2200             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    2201             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    2202             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    2203             :     end function
    2204             : #endif
    2205             : 
    2206             : #if IK3_ENABLED
    2207             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_IK3(array, pattern, replacement) result(arrayNew)
    2208             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2209             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_IK3
    2210             : #endif
    2211             :         use pm_kind, only: IKC => IK3
    2212             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    2213             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    2214             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    2215             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    2216             :     end function
    2217             : #endif
    2218             : 
    2219             : #if IK2_ENABLED
    2220             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_IK2(array, pattern, replacement) result(arrayNew)
    2221             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2222             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_IK2
    2223             : #endif
    2224             :         use pm_kind, only: IKC => IK2
    2225             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    2226             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    2227             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    2228             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    2229             :     end function
    2230             : 
    2231             : #endif
    2232             : 
    2233             : #if IK1_ENABLED
    2234             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_IK1(array, pattern, replacement) result(arrayNew)
    2235             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2236             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_IK1
    2237             : #endif
    2238             :         use pm_kind, only: IKC => IK1
    2239             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    2240             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    2241             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    2242             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    2243             :     end function
    2244             : #endif
    2245             : 
    2246             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2247             : 
    2248             : #if LK5_ENABLED
    2249             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_LK5(array, pattern, replacement) result(arrayNew)
    2250             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2251             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_LK5
    2252             : #endif
    2253             :         use pm_kind, only: LKC => LK5
    2254             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    2255             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    2256             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    2257             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    2258             :     end function
    2259             : #endif
    2260             : 
    2261             : #if LK4_ENABLED
    2262             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_LK4(array, pattern, replacement) result(arrayNew)
    2263             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2264             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_LK4
    2265             : #endif
    2266             :         use pm_kind, only: LKC => LK4
    2267             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    2268             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    2269             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    2270             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    2271             :     end function
    2272             : #endif
    2273             : 
    2274             : #if LK3_ENABLED
    2275             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_LK3(array, pattern, replacement) result(arrayNew)
    2276             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2277             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_LK3
    2278             : #endif
    2279             :         use pm_kind, only: LKC => LK3
    2280             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    2281             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    2282             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    2283             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    2284             :     end function
    2285             : #endif
    2286             : 
    2287             : #if LK2_ENABLED
    2288             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_LK2(array, pattern, replacement) result(arrayNew)
    2289             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2290             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_LK2
    2291             : #endif
    2292             :         use pm_kind, only: LKC => LK2
    2293             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    2294             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    2295             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    2296             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    2297             :     end function
    2298             : 
    2299             : #endif
    2300             : 
    2301             : #if LK1_ENABLED
    2302             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_LK1(array, pattern, replacement) result(arrayNew)
    2303             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2304             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_LK1
    2305             : #endif
    2306             :         use pm_kind, only: LKC => LK1
    2307             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    2308             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    2309             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    2310             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    2311             :     end function
    2312             : #endif
    2313             : 
    2314             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2315             : 
    2316             : #if CK5_ENABLED
    2317             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_CK5(array, pattern, replacement) result(arrayNew)
    2318             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2319             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_CK5
    2320             : #endif
    2321             :         use pm_kind, only: CKC => CK5
    2322             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2323             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    2324             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    2325             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2326             :     end function
    2327             : #endif
    2328             : 
    2329             : #if CK4_ENABLED
    2330             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_CK4(array, pattern, replacement) result(arrayNew)
    2331             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2332             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_CK4
    2333             : #endif
    2334             :         use pm_kind, only: CKC => CK4
    2335             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2336             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    2337             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    2338             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2339             :     end function
    2340             : #endif
    2341             : 
    2342             : #if CK3_ENABLED
    2343             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_CK3(array, pattern, replacement) result(arrayNew)
    2344             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2345             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_CK3
    2346             : #endif
    2347             :         use pm_kind, only: CKC => CK3
    2348             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2349             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    2350             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    2351             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2352             :     end function
    2353             : #endif
    2354             : 
    2355             : #if CK2_ENABLED
    2356             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_CK2(array, pattern, replacement) result(arrayNew)
    2357             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2358             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_CK2
    2359             : #endif
    2360             :         use pm_kind, only: CKC => CK2
    2361             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2362             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    2363             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    2364             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2365             :     end function
    2366             : 
    2367             : #endif
    2368             : 
    2369             : #if CK1_ENABLED
    2370             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_CK1(array, pattern, replacement) result(arrayNew)
    2371             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2372             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_CK1
    2373             : #endif
    2374             :         use pm_kind, only: CKC => CK1
    2375             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2376             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    2377             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    2378             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2379             :     end function
    2380             : #endif
    2381             : 
    2382             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2383             : 
    2384             : #if RK5_ENABLED
    2385             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_RK5(array, pattern, replacement) result(arrayNew)
    2386             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2387             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_RK5
    2388             : #endif
    2389             :         use pm_kind, only: RKC => RK5
    2390             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2391             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    2392             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    2393             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2394             :     end function
    2395             : #endif
    2396             : 
    2397             : #if RK4_ENABLED
    2398             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_RK4(array, pattern, replacement) result(arrayNew)
    2399             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2400             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_RK4
    2401             : #endif
    2402             :         use pm_kind, only: RKC => RK4
    2403             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2404             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    2405             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    2406             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2407             :     end function
    2408             : #endif
    2409             : 
    2410             : #if RK3_ENABLED
    2411             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_RK3(array, pattern, replacement) result(arrayNew)
    2412             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2413             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_RK3
    2414             : #endif
    2415             :         use pm_kind, only: RKC => RK3
    2416             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2417             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    2418             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    2419             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2420             :     end function
    2421             : #endif
    2422             : 
    2423             : #if RK2_ENABLED
    2424             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_RK2(array, pattern, replacement) result(arrayNew)
    2425             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2426             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_RK2
    2427             : #endif
    2428             :         use pm_kind, only: RKC => RK2
    2429             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2430             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    2431             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    2432             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2433             :     end function
    2434             : 
    2435             : #endif
    2436             : 
    2437             : #if RK1_ENABLED
    2438             :     PURE module function getReplacedDefComDefIns_D1_D1_D1_RK1(array, pattern, replacement) result(arrayNew)
    2439             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2440             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComDefIns_D1_D1_D1_RK1
    2441             : #endif
    2442             :         use pm_kind, only: RKC => RK1
    2443             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2444             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    2445             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    2446             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2447             :     end function
    2448             : #endif
    2449             : 
    2450             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2451             : 
    2452             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2453             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2454             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2455             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2456             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2457             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2458             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2459             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2460             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2461             : 
    2462             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2463             : 
    2464             : #if SK5_ENABLED
    2465             :     module function getReplacedCusComDefIns_D0_D0_D0_SK5(array, pattern, replacement, iseq) result(arrayNew)
    2466             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2467             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D0_D0_D0_SK5
    2468             : #endif
    2469             :         use pm_kind, only: SKC => SK5
    2470             :         character(*,SKC)        , intent(in)                    :: array
    2471             :         character(*,SKC)        , intent(in)                    :: pattern
    2472             :         character(*,SKC)        , intent(in)                    :: replacement
    2473             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
    2474             :         procedure(logical(LK))                                  :: iseq
    2475             :         character(:,SKC)                        , allocatable   :: arrayNew
    2476             :     end function
    2477             : #endif
    2478             : 
    2479             : #if SK4_ENABLED
    2480             :     module function getReplacedCusComDefIns_D0_D0_D0_SK4(array, pattern, replacement, iseq) result(arrayNew)
    2481             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2482             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D0_D0_D0_SK4
    2483             : #endif
    2484             :         use pm_kind, only: SKC => SK4
    2485             :         character(*,SKC)        , intent(in)                    :: array
    2486             :         character(*,SKC)        , intent(in)                    :: pattern
    2487             :         character(*,SKC)        , intent(in)                    :: replacement
    2488             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
    2489             :         procedure(logical(LK))                                  :: iseq
    2490             :         character(:,SKC)                        , allocatable   :: arrayNew
    2491             :     end function
    2492             : #endif
    2493             : 
    2494             : #if SK3_ENABLED
    2495             :     module function getReplacedCusComDefIns_D0_D0_D0_SK3(array, pattern, replacement, iseq) result(arrayNew)
    2496             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2497             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D0_D0_D0_SK3
    2498             : #endif
    2499             :         use pm_kind, only: SKC => SK3
    2500             :         character(*,SKC)        , intent(in)                    :: array
    2501             :         character(*,SKC)        , intent(in)                    :: pattern
    2502             :         character(*,SKC)        , intent(in)                    :: replacement
    2503             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
    2504             :         procedure(logical(LK))                                  :: iseq
    2505             :         character(:,SKC)                        , allocatable   :: arrayNew
    2506             :     end function
    2507             : #endif
    2508             : 
    2509             : #if SK2_ENABLED
    2510             :     module function getReplacedCusComDefIns_D0_D0_D0_SK2(array, pattern, replacement, iseq) result(arrayNew)
    2511             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2512             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D0_D0_D0_SK2
    2513             : #endif
    2514             :         use pm_kind, only: SKC => SK2
    2515             :         character(*,SKC)        , intent(in)                    :: array
    2516             :         character(*,SKC)        , intent(in)                    :: pattern
    2517             :         character(*,SKC)        , intent(in)                    :: replacement
    2518             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
    2519             :         procedure(logical(LK))                                  :: iseq
    2520             :         character(:,SKC)                        , allocatable   :: arrayNew
    2521             :     end function
    2522             : 
    2523             : #endif
    2524             : 
    2525             : #if SK1_ENABLED
    2526             :     module function getReplacedCusComDefIns_D0_D0_D0_SK1(array, pattern, replacement, iseq) result(arrayNew)
    2527             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2528             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D0_D0_D0_SK1
    2529             : #endif
    2530             :         use pm_kind, only: SKC => SK1
    2531             :         character(*,SKC)        , intent(in)                    :: array
    2532             :         character(*,SKC)        , intent(in)                    :: pattern
    2533             :         character(*,SKC)        , intent(in)                    :: replacement
    2534             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
    2535             :         procedure(logical(LK))                                  :: iseq
    2536             :         character(:,SKC)                        , allocatable   :: arrayNew
    2537             :     end function
    2538             : #endif
    2539             : 
    2540             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2541             : 
    2542             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2543             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2544             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2545             : 
    2546             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2547             : 
    2548             : #if SK5_ENABLED
    2549             :     module function getReplacedCusComDefIns_D1_D0_D0_SK5(array, pattern, replacement, iseq) result(arrayNew)
    2550             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2551             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_SK5
    2552             : #endif
    2553             :         use pm_kind, only: SKC => SK5
    2554             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2555             :         character(*,SKC)        , intent(in)                    :: pattern
    2556             :         character(*,SKC)        , intent(in)                    :: replacement
    2557             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
    2558             :         procedure(logical(LK))                                  :: iseq
    2559             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2560             :     end function
    2561             : #endif
    2562             : 
    2563             : #if SK4_ENABLED
    2564             :     module function getReplacedCusComDefIns_D1_D0_D0_SK4(array, pattern, replacement, iseq) result(arrayNew)
    2565             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2566             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_SK4
    2567             : #endif
    2568             :         use pm_kind, only: SKC => SK4
    2569             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2570             :         character(*,SKC)        , intent(in)                    :: pattern
    2571             :         character(*,SKC)        , intent(in)                    :: replacement
    2572             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
    2573             :         procedure(logical(LK))                                  :: iseq
    2574             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2575             :     end function
    2576             : #endif
    2577             : 
    2578             : #if SK3_ENABLED
    2579             :     module function getReplacedCusComDefIns_D1_D0_D0_SK3(array, pattern, replacement, iseq) result(arrayNew)
    2580             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2581             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_SK3
    2582             : #endif
    2583             :         use pm_kind, only: SKC => SK3
    2584             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2585             :         character(*,SKC)        , intent(in)                    :: pattern
    2586             :         character(*,SKC)        , intent(in)                    :: replacement
    2587             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
    2588             :         procedure(logical(LK))                                  :: iseq
    2589             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2590             :     end function
    2591             : #endif
    2592             : 
    2593             : #if SK2_ENABLED
    2594             :     module function getReplacedCusComDefIns_D1_D0_D0_SK2(array, pattern, replacement, iseq) result(arrayNew)
    2595             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2596             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_SK2
    2597             : #endif
    2598             :         use pm_kind, only: SKC => SK2
    2599             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2600             :         character(*,SKC)        , intent(in)                    :: pattern
    2601             :         character(*,SKC)        , intent(in)                    :: replacement
    2602             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
    2603             :         procedure(logical(LK))                                  :: iseq
    2604             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2605             :     end function
    2606             : 
    2607             : #endif
    2608             : 
    2609             : #if SK1_ENABLED
    2610             :     module function getReplacedCusComDefIns_D1_D0_D0_SK1(array, pattern, replacement, iseq) result(arrayNew)
    2611             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2612             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_SK1
    2613             : #endif
    2614             :         use pm_kind, only: SKC => SK1
    2615             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2616             :         character(*,SKC)        , intent(in)                    :: pattern
    2617             :         character(*,SKC)        , intent(in)                    :: replacement
    2618             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
    2619             :         procedure(logical(LK))                                  :: iseq
    2620             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2621             :     end function
    2622             : #endif
    2623             : 
    2624             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2625             : 
    2626             : #if IK5_ENABLED
    2627             :     module function getReplacedCusComDefIns_D1_D0_D0_IK5(array, pattern, replacement, iseq) result(arrayNew)
    2628             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2629             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_IK5
    2630             : #endif
    2631             :         use pm_kind, only: IKC => IK5
    2632             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    2633             :         integer(IKC)            , intent(in)                    :: pattern
    2634             :         integer(IKC)            , intent(in)                    :: replacement
    2635             :        !procedure(iseq_D0_D0_IK5)                               :: iseq
    2636             :         procedure(logical(LK))                                  :: iseq
    2637             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    2638             :     end function
    2639             : #endif
    2640             : 
    2641             : #if IK4_ENABLED
    2642             :     module function getReplacedCusComDefIns_D1_D0_D0_IK4(array, pattern, replacement, iseq) result(arrayNew)
    2643             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2644             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_IK4
    2645             : #endif
    2646             :         use pm_kind, only: IKC => IK4
    2647             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    2648             :         integer(IKC)            , intent(in)                    :: pattern
    2649             :         integer(IKC)            , intent(in)                    :: replacement
    2650             :        !procedure(iseq_D0_D0_IK4)                               :: iseq
    2651             :         procedure(logical(LK))                                  :: iseq
    2652             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    2653             :     end function
    2654             : #endif
    2655             : 
    2656             : #if IK3_ENABLED
    2657             :     module function getReplacedCusComDefIns_D1_D0_D0_IK3(array, pattern, replacement, iseq) result(arrayNew)
    2658             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2659             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_IK3
    2660             : #endif
    2661             :         use pm_kind, only: IKC => IK3
    2662             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    2663             :         integer(IKC)            , intent(in)                    :: pattern
    2664             :         integer(IKC)            , intent(in)                    :: replacement
    2665             :        !procedure(iseq_D0_D0_IK3)                               :: iseq
    2666             :         procedure(logical(LK))                                  :: iseq
    2667             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    2668             :     end function
    2669             : #endif
    2670             : 
    2671             : #if IK2_ENABLED
    2672             :     module function getReplacedCusComDefIns_D1_D0_D0_IK2(array, pattern, replacement, iseq) result(arrayNew)
    2673             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2674             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_IK2
    2675             : #endif
    2676             :         use pm_kind, only: IKC => IK2
    2677             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    2678             :         integer(IKC)            , intent(in)                    :: pattern
    2679             :         integer(IKC)            , intent(in)                    :: replacement
    2680             :        !procedure(iseq_D0_D0_IK2)                               :: iseq
    2681             :         procedure(logical(LK))                                  :: iseq
    2682             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    2683             :     end function
    2684             : 
    2685             : #endif
    2686             : 
    2687             : #if IK1_ENABLED
    2688             :     module function getReplacedCusComDefIns_D1_D0_D0_IK1(array, pattern, replacement, iseq) result(arrayNew)
    2689             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2690             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_IK1
    2691             : #endif
    2692             :         use pm_kind, only: IKC => IK1
    2693             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    2694             :         integer(IKC)            , intent(in)                    :: pattern
    2695             :         integer(IKC)            , intent(in)                    :: replacement
    2696             :        !procedure(iseq_D0_D0_IK1)                               :: iseq
    2697             :         procedure(logical(LK))                                  :: iseq
    2698             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    2699             :     end function
    2700             : #endif
    2701             : 
    2702             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2703             : 
    2704             : #if LK5_ENABLED
    2705             :     module function getReplacedCusComDefIns_D1_D0_D0_LK5(array, pattern, replacement, iseq) result(arrayNew)
    2706             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2707             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_LK5
    2708             : #endif
    2709             :         use pm_kind, only: LKC => LK5
    2710             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    2711             :         logical(LKC)            , intent(in)                    :: pattern
    2712             :         logical(LKC)            , intent(in)                    :: replacement
    2713             :        !procedure(iseq_D0_D0_LK5)                               :: iseq
    2714             :         procedure(logical(LK))                                  :: iseq
    2715             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    2716             :     end function
    2717             : #endif
    2718             : 
    2719             : #if LK4_ENABLED
    2720             :     module function getReplacedCusComDefIns_D1_D0_D0_LK4(array, pattern, replacement, iseq) result(arrayNew)
    2721             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2722             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_LK4
    2723             : #endif
    2724             :         use pm_kind, only: LKC => LK4
    2725             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    2726             :         logical(LKC)            , intent(in)                    :: pattern
    2727             :         logical(LKC)            , intent(in)                    :: replacement
    2728             :        !procedure(iseq_D0_D0_LK4)                               :: iseq
    2729             :         procedure(logical(LK))                                  :: iseq
    2730             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    2731             :     end function
    2732             : #endif
    2733             : 
    2734             : #if LK3_ENABLED
    2735             :     module function getReplacedCusComDefIns_D1_D0_D0_LK3(array, pattern, replacement, iseq) result(arrayNew)
    2736             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2737             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_LK3
    2738             : #endif
    2739             :         use pm_kind, only: LKC => LK3
    2740             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    2741             :         logical(LKC)            , intent(in)                    :: pattern
    2742             :         logical(LKC)            , intent(in)                    :: replacement
    2743             :        !procedure(iseq_D0_D0_LK3)                               :: iseq
    2744             :         procedure(logical(LK))                                  :: iseq
    2745             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    2746             :     end function
    2747             : #endif
    2748             : 
    2749             : #if LK2_ENABLED
    2750             :     module function getReplacedCusComDefIns_D1_D0_D0_LK2(array, pattern, replacement, iseq) result(arrayNew)
    2751             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2752             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_LK2
    2753             : #endif
    2754             :         use pm_kind, only: LKC => LK2
    2755             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    2756             :         logical(LKC)            , intent(in)                    :: pattern
    2757             :         logical(LKC)            , intent(in)                    :: replacement
    2758             :        !procedure(iseq_D0_D0_LK2)                               :: iseq
    2759             :         procedure(logical(LK))                                  :: iseq
    2760             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    2761             :     end function
    2762             : 
    2763             : #endif
    2764             : 
    2765             : #if LK1_ENABLED
    2766             :     module function getReplacedCusComDefIns_D1_D0_D0_LK1(array, pattern, replacement, iseq) result(arrayNew)
    2767             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2768             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_LK1
    2769             : #endif
    2770             :         use pm_kind, only: LKC => LK1
    2771             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    2772             :         logical(LKC)            , intent(in)                    :: pattern
    2773             :         logical(LKC)            , intent(in)                    :: replacement
    2774             :        !procedure(iseq_D0_D0_LK1)                               :: iseq
    2775             :         procedure(logical(LK))                                  :: iseq
    2776             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    2777             :     end function
    2778             : #endif
    2779             : 
    2780             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2781             : 
    2782             : #if CK5_ENABLED
    2783             :     module function getReplacedCusComDefIns_D1_D0_D0_CK5(array, pattern, replacement, iseq) result(arrayNew)
    2784             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2785             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_CK5
    2786             : #endif
    2787             :         use pm_kind, only: CKC => CK5
    2788             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2789             :         complex(CKC)            , intent(in)                    :: pattern
    2790             :         complex(CKC)            , intent(in)                    :: replacement
    2791             :        !procedure(iseq_D0_D0_CK5)                               :: iseq
    2792             :         procedure(logical(LK))                                  :: iseq
    2793             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2794             :     end function
    2795             : #endif
    2796             : 
    2797             : #if CK4_ENABLED
    2798             :     module function getReplacedCusComDefIns_D1_D0_D0_CK4(array, pattern, replacement, iseq) result(arrayNew)
    2799             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2800             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_CK4
    2801             : #endif
    2802             :         use pm_kind, only: CKC => CK4
    2803             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2804             :         complex(CKC)            , intent(in)                    :: pattern
    2805             :         complex(CKC)            , intent(in)                    :: replacement
    2806             :        !procedure(iseq_D0_D0_CK4)                               :: iseq
    2807             :         procedure(logical(LK))                                  :: iseq
    2808             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2809             :     end function
    2810             : #endif
    2811             : 
    2812             : #if CK3_ENABLED
    2813             :     module function getReplacedCusComDefIns_D1_D0_D0_CK3(array, pattern, replacement, iseq) result(arrayNew)
    2814             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2815             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_CK3
    2816             : #endif
    2817             :         use pm_kind, only: CKC => CK3
    2818             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2819             :         complex(CKC)            , intent(in)                    :: pattern
    2820             :         complex(CKC)            , intent(in)                    :: replacement
    2821             :        !procedure(iseq_D0_D0_CK3)                               :: iseq
    2822             :         procedure(logical(LK))                                  :: iseq
    2823             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2824             :     end function
    2825             : #endif
    2826             : 
    2827             : #if CK2_ENABLED
    2828             :     module function getReplacedCusComDefIns_D1_D0_D0_CK2(array, pattern, replacement, iseq) result(arrayNew)
    2829             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2830             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_CK2
    2831             : #endif
    2832             :         use pm_kind, only: CKC => CK2
    2833             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2834             :         complex(CKC)            , intent(in)                    :: pattern
    2835             :         complex(CKC)            , intent(in)                    :: replacement
    2836             :        !procedure(iseq_D0_D0_CK2)                               :: iseq
    2837             :         procedure(logical(LK))                                  :: iseq
    2838             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2839             :     end function
    2840             : 
    2841             : #endif
    2842             : 
    2843             : #if CK1_ENABLED
    2844             :     module function getReplacedCusComDefIns_D1_D0_D0_CK1(array, pattern, replacement, iseq) result(arrayNew)
    2845             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2846             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_CK1
    2847             : #endif
    2848             :         use pm_kind, only: CKC => CK1
    2849             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    2850             :         complex(CKC)            , intent(in)                    :: pattern
    2851             :         complex(CKC)            , intent(in)                    :: replacement
    2852             :        !procedure(iseq_D0_D0_CK1)                               :: iseq
    2853             :         procedure(logical(LK))                                  :: iseq
    2854             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    2855             :     end function
    2856             : #endif
    2857             : 
    2858             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2859             : 
    2860             : #if RK5_ENABLED
    2861             :     module function getReplacedCusComDefIns_D1_D0_D0_RK5(array, pattern, replacement, iseq) result(arrayNew)
    2862             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2863             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_RK5
    2864             : #endif
    2865             :         use pm_kind, only: RKC => RK5
    2866             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2867             :         real(RKC)               , intent(in)                    :: pattern
    2868             :         real(RKC)               , intent(in)                    :: replacement
    2869             :        !procedure(iseq_D0_D0_RK5)                               :: iseq
    2870             :         procedure(logical(LK))                                  :: iseq
    2871             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2872             :     end function
    2873             : #endif
    2874             : 
    2875             : #if RK4_ENABLED
    2876             :     module function getReplacedCusComDefIns_D1_D0_D0_RK4(array, pattern, replacement, iseq) result(arrayNew)
    2877             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2878             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_RK4
    2879             : #endif
    2880             :         use pm_kind, only: RKC => RK4
    2881             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2882             :         real(RKC)               , intent(in)                    :: pattern
    2883             :         real(RKC)               , intent(in)                    :: replacement
    2884             :        !procedure(iseq_D0_D0_RK4)                               :: iseq
    2885             :         procedure(logical(LK))                                  :: iseq
    2886             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2887             :     end function
    2888             : #endif
    2889             : 
    2890             : #if RK3_ENABLED
    2891             :     module function getReplacedCusComDefIns_D1_D0_D0_RK3(array, pattern, replacement, iseq) result(arrayNew)
    2892             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2893             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_RK3
    2894             : #endif
    2895             :         use pm_kind, only: RKC => RK3
    2896             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2897             :         real(RKC)               , intent(in)                    :: pattern
    2898             :         real(RKC)               , intent(in)                    :: replacement
    2899             :        !procedure(iseq_D0_D0_RK3)                               :: iseq
    2900             :         procedure(logical(LK))                                  :: iseq
    2901             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2902             :     end function
    2903             : #endif
    2904             : 
    2905             : #if RK2_ENABLED
    2906             :     module function getReplacedCusComDefIns_D1_D0_D0_RK2(array, pattern, replacement, iseq) result(arrayNew)
    2907             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2908             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_RK2
    2909             : #endif
    2910             :         use pm_kind, only: RKC => RK2
    2911             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2912             :         real(RKC)               , intent(in)                    :: pattern
    2913             :         real(RKC)               , intent(in)                    :: replacement
    2914             :        !procedure(iseq_D0_D0_RK2)                               :: iseq
    2915             :         procedure(logical(LK))                                  :: iseq
    2916             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2917             :     end function
    2918             : 
    2919             : #endif
    2920             : 
    2921             : #if RK1_ENABLED
    2922             :     module function getReplacedCusComDefIns_D1_D0_D0_RK1(array, pattern, replacement, iseq) result(arrayNew)
    2923             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2924             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D0_RK1
    2925             : #endif
    2926             :         use pm_kind, only: RKC => RK1
    2927             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    2928             :         real(RKC)               , intent(in)                    :: pattern
    2929             :         real(RKC)               , intent(in)                    :: replacement
    2930             :        !procedure(iseq_D0_D0_RK1)                               :: iseq
    2931             :         procedure(logical(LK))                                  :: iseq
    2932             :         real(RKC)                               , allocatable   :: arrayNew(:)
    2933             :     end function
    2934             : #endif
    2935             : 
    2936             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2937             : 
    2938             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2939             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2940             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2941             : 
    2942             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    2943             : 
    2944             : #if SK5_ENABLED
    2945             :     module function getReplacedCusComDefIns_D1_D0_D1_SK5(array, pattern, replacement, iseq) result(arrayNew)
    2946             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2947             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_SK5
    2948             : #endif
    2949             :         use pm_kind, only: SKC => SK5
    2950             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2951             :         character(*,SKC)        , intent(in)                    :: pattern
    2952             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    2953             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
    2954             :         procedure(logical(LK))                                  :: iseq
    2955             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2956             :     end function
    2957             : #endif
    2958             : 
    2959             : #if SK4_ENABLED
    2960             :     module function getReplacedCusComDefIns_D1_D0_D1_SK4(array, pattern, replacement, iseq) result(arrayNew)
    2961             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2962             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_SK4
    2963             : #endif
    2964             :         use pm_kind, only: SKC => SK4
    2965             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2966             :         character(*,SKC)        , intent(in)                    :: pattern
    2967             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    2968             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
    2969             :         procedure(logical(LK))                                  :: iseq
    2970             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2971             :     end function
    2972             : #endif
    2973             : 
    2974             : #if SK3_ENABLED
    2975             :     module function getReplacedCusComDefIns_D1_D0_D1_SK3(array, pattern, replacement, iseq) result(arrayNew)
    2976             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2977             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_SK3
    2978             : #endif
    2979             :         use pm_kind, only: SKC => SK3
    2980             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2981             :         character(*,SKC)        , intent(in)                    :: pattern
    2982             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    2983             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
    2984             :         procedure(logical(LK))                                  :: iseq
    2985             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    2986             :     end function
    2987             : #endif
    2988             : 
    2989             : #if SK2_ENABLED
    2990             :     module function getReplacedCusComDefIns_D1_D0_D1_SK2(array, pattern, replacement, iseq) result(arrayNew)
    2991             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    2992             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_SK2
    2993             : #endif
    2994             :         use pm_kind, only: SKC => SK2
    2995             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    2996             :         character(*,SKC)        , intent(in)                    :: pattern
    2997             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    2998             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
    2999             :         procedure(logical(LK))                                  :: iseq
    3000             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3001             :     end function
    3002             : 
    3003             : #endif
    3004             : 
    3005             : #if SK1_ENABLED
    3006             :     module function getReplacedCusComDefIns_D1_D0_D1_SK1(array, pattern, replacement, iseq) result(arrayNew)
    3007             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3008             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_SK1
    3009             : #endif
    3010             :         use pm_kind, only: SKC => SK1
    3011             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3012             :         character(*,SKC)        , intent(in)                    :: pattern
    3013             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    3014             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
    3015             :         procedure(logical(LK))                                  :: iseq
    3016             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3017             :     end function
    3018             : #endif
    3019             : 
    3020             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3021             : 
    3022             : #if IK5_ENABLED
    3023             :     module function getReplacedCusComDefIns_D1_D0_D1_IK5(array, pattern, replacement, iseq) result(arrayNew)
    3024             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3025             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_IK5
    3026             : #endif
    3027             :         use pm_kind, only: IKC => IK5
    3028             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3029             :         integer(IKC)            , intent(in)                    :: pattern
    3030             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    3031             :        !procedure(iseq_D0_D0_IK5)                               :: iseq
    3032             :         procedure(logical(LK))                                  :: iseq
    3033             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3034             :     end function
    3035             : #endif
    3036             : 
    3037             : #if IK4_ENABLED
    3038             :     module function getReplacedCusComDefIns_D1_D0_D1_IK4(array, pattern, replacement, iseq) result(arrayNew)
    3039             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3040             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_IK4
    3041             : #endif
    3042             :         use pm_kind, only: IKC => IK4
    3043             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3044             :         integer(IKC)            , intent(in)                    :: pattern
    3045             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    3046             :        !procedure(iseq_D0_D0_IK4)                               :: iseq
    3047             :         procedure(logical(LK))                                  :: iseq
    3048             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3049             :     end function
    3050             : #endif
    3051             : 
    3052             : #if IK3_ENABLED
    3053             :     module function getReplacedCusComDefIns_D1_D0_D1_IK3(array, pattern, replacement, iseq) result(arrayNew)
    3054             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3055             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_IK3
    3056             : #endif
    3057             :         use pm_kind, only: IKC => IK3
    3058             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3059             :         integer(IKC)            , intent(in)                    :: pattern
    3060             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    3061             :        !procedure(iseq_D0_D0_IK3)                               :: iseq
    3062             :         procedure(logical(LK))                                  :: iseq
    3063             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3064             :     end function
    3065             : #endif
    3066             : 
    3067             : #if IK2_ENABLED
    3068             :     module function getReplacedCusComDefIns_D1_D0_D1_IK2(array, pattern, replacement, iseq) result(arrayNew)
    3069             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3070             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_IK2
    3071             : #endif
    3072             :         use pm_kind, only: IKC => IK2
    3073             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3074             :         integer(IKC)            , intent(in)                    :: pattern
    3075             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    3076             :        !procedure(iseq_D0_D0_IK2)                               :: iseq
    3077             :         procedure(logical(LK))                                  :: iseq
    3078             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3079             :     end function
    3080             : 
    3081             : #endif
    3082             : 
    3083             : #if IK1_ENABLED
    3084             :     module function getReplacedCusComDefIns_D1_D0_D1_IK1(array, pattern, replacement, iseq) result(arrayNew)
    3085             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3086             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_IK1
    3087             : #endif
    3088             :         use pm_kind, only: IKC => IK1
    3089             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3090             :         integer(IKC)            , intent(in)                    :: pattern
    3091             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    3092             :        !procedure(iseq_D0_D0_IK1)                               :: iseq
    3093             :         procedure(logical(LK))                                  :: iseq
    3094             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3095             :     end function
    3096             : #endif
    3097             : 
    3098             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3099             : 
    3100             : #if LK5_ENABLED
    3101             :     module function getReplacedCusComDefIns_D1_D0_D1_LK5(array, pattern, replacement, iseq) result(arrayNew)
    3102             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3103             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_LK5
    3104             : #endif
    3105             :         use pm_kind, only: LKC => LK5
    3106             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3107             :         logical(LKC)            , intent(in)                    :: pattern
    3108             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    3109             :        !procedure(iseq_D0_D0_LK5)                               :: iseq
    3110             :         procedure(logical(LK))                                  :: iseq
    3111             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3112             :     end function
    3113             : #endif
    3114             : 
    3115             : #if LK4_ENABLED
    3116             :     module function getReplacedCusComDefIns_D1_D0_D1_LK4(array, pattern, replacement, iseq) result(arrayNew)
    3117             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3118             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_LK4
    3119             : #endif
    3120             :         use pm_kind, only: LKC => LK4
    3121             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3122             :         logical(LKC)            , intent(in)                    :: pattern
    3123             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    3124             :        !procedure(iseq_D0_D0_LK4)                               :: iseq
    3125             :         procedure(logical(LK))                                  :: iseq
    3126             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3127             :     end function
    3128             : #endif
    3129             : 
    3130             : #if LK3_ENABLED
    3131             :     module function getReplacedCusComDefIns_D1_D0_D1_LK3(array, pattern, replacement, iseq) result(arrayNew)
    3132             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3133             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_LK3
    3134             : #endif
    3135             :         use pm_kind, only: LKC => LK3
    3136             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3137             :         logical(LKC)            , intent(in)                    :: pattern
    3138             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    3139             :        !procedure(iseq_D0_D0_LK3)                               :: iseq
    3140             :         procedure(logical(LK))                                  :: iseq
    3141             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3142             :     end function
    3143             : #endif
    3144             : 
    3145             : #if LK2_ENABLED
    3146             :     module function getReplacedCusComDefIns_D1_D0_D1_LK2(array, pattern, replacement, iseq) result(arrayNew)
    3147             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3148             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_LK2
    3149             : #endif
    3150             :         use pm_kind, only: LKC => LK2
    3151             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3152             :         logical(LKC)            , intent(in)                    :: pattern
    3153             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    3154             :        !procedure(iseq_D0_D0_LK2)                               :: iseq
    3155             :         procedure(logical(LK))                                  :: iseq
    3156             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3157             :     end function
    3158             : 
    3159             : #endif
    3160             : 
    3161             : #if LK1_ENABLED
    3162             :     module function getReplacedCusComDefIns_D1_D0_D1_LK1(array, pattern, replacement, iseq) result(arrayNew)
    3163             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3164             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_LK1
    3165             : #endif
    3166             :         use pm_kind, only: LKC => LK1
    3167             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3168             :         logical(LKC)            , intent(in)                    :: pattern
    3169             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    3170             :        !procedure(iseq_D0_D0_LK1)                               :: iseq
    3171             :         procedure(logical(LK))                                  :: iseq
    3172             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3173             :     end function
    3174             : #endif
    3175             : 
    3176             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3177             : 
    3178             : #if CK5_ENABLED
    3179             :     module function getReplacedCusComDefIns_D1_D0_D1_CK5(array, pattern, replacement, iseq) result(arrayNew)
    3180             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3181             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_CK5
    3182             : #endif
    3183             :         use pm_kind, only: CKC => CK5
    3184             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3185             :         complex(CKC)            , intent(in)                    :: pattern
    3186             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    3187             :        !procedure(iseq_D0_D0_CK5)                               :: iseq
    3188             :         procedure(logical(LK))                                  :: iseq
    3189             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3190             :     end function
    3191             : #endif
    3192             : 
    3193             : #if CK4_ENABLED
    3194             :     module function getReplacedCusComDefIns_D1_D0_D1_CK4(array, pattern, replacement, iseq) result(arrayNew)
    3195             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3196             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_CK4
    3197             : #endif
    3198             :         use pm_kind, only: CKC => CK4
    3199             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3200             :         complex(CKC)            , intent(in)                    :: pattern
    3201             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    3202             :        !procedure(iseq_D0_D0_CK4)                               :: iseq
    3203             :         procedure(logical(LK))                                  :: iseq
    3204             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3205             :     end function
    3206             : #endif
    3207             : 
    3208             : #if CK3_ENABLED
    3209             :     module function getReplacedCusComDefIns_D1_D0_D1_CK3(array, pattern, replacement, iseq) result(arrayNew)
    3210             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3211             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_CK3
    3212             : #endif
    3213             :         use pm_kind, only: CKC => CK3
    3214             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3215             :         complex(CKC)            , intent(in)                    :: pattern
    3216             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    3217             :        !procedure(iseq_D0_D0_CK3)                               :: iseq
    3218             :         procedure(logical(LK))                                  :: iseq
    3219             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3220             :     end function
    3221             : #endif
    3222             : 
    3223             : #if CK2_ENABLED
    3224             :     module function getReplacedCusComDefIns_D1_D0_D1_CK2(array, pattern, replacement, iseq) result(arrayNew)
    3225             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3226             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_CK2
    3227             : #endif
    3228             :         use pm_kind, only: CKC => CK2
    3229             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3230             :         complex(CKC)            , intent(in)                    :: pattern
    3231             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    3232             :        !procedure(iseq_D0_D0_CK2)                               :: iseq
    3233             :         procedure(logical(LK))                                  :: iseq
    3234             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3235             :     end function
    3236             : 
    3237             : #endif
    3238             : 
    3239             : #if CK1_ENABLED
    3240             :     module function getReplacedCusComDefIns_D1_D0_D1_CK1(array, pattern, replacement, iseq) result(arrayNew)
    3241             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3242             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_CK1
    3243             : #endif
    3244             :         use pm_kind, only: CKC => CK1
    3245             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3246             :         complex(CKC)            , intent(in)                    :: pattern
    3247             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    3248             :        !procedure(iseq_D0_D0_CK1)                               :: iseq
    3249             :         procedure(logical(LK))                                  :: iseq
    3250             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3251             :     end function
    3252             : #endif
    3253             : 
    3254             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3255             : 
    3256             : #if RK5_ENABLED
    3257             :     module function getReplacedCusComDefIns_D1_D0_D1_RK5(array, pattern, replacement, iseq) result(arrayNew)
    3258             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3259             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_RK5
    3260             : #endif
    3261             :         use pm_kind, only: RKC => RK5
    3262             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    3263             :         real(RKC)               , intent(in)                    :: pattern
    3264             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    3265             :        !procedure(iseq_D0_D0_RK5)                               :: iseq
    3266             :         procedure(logical(LK))                                  :: iseq
    3267             :         real(RKC)                               , allocatable   :: arrayNew(:)
    3268             :     end function
    3269             : #endif
    3270             : 
    3271             : #if RK4_ENABLED
    3272             :     module function getReplacedCusComDefIns_D1_D0_D1_RK4(array, pattern, replacement, iseq) result(arrayNew)
    3273             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3274             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_RK4
    3275             : #endif
    3276             :         use pm_kind, only: RKC => RK4
    3277             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    3278             :         real(RKC)               , intent(in)                    :: pattern
    3279             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    3280             :        !procedure(iseq_D0_D0_RK4)                               :: iseq
    3281             :         procedure(logical(LK))                                  :: iseq
    3282             :         real(RKC)                               , allocatable   :: arrayNew(:)
    3283             :     end function
    3284             : #endif
    3285             : 
    3286             : #if RK3_ENABLED
    3287             :     module function getReplacedCusComDefIns_D1_D0_D1_RK3(array, pattern, replacement, iseq) result(arrayNew)
    3288             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3289             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_RK3
    3290             : #endif
    3291             :         use pm_kind, only: RKC => RK3
    3292             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    3293             :         real(RKC)               , intent(in)                    :: pattern
    3294             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    3295             :        !procedure(iseq_D0_D0_RK3)                               :: iseq
    3296             :         procedure(logical(LK))                                  :: iseq
    3297             :         real(RKC)                               , allocatable   :: arrayNew(:)
    3298             :     end function
    3299             : #endif
    3300             : 
    3301             : #if RK2_ENABLED
    3302             :     module function getReplacedCusComDefIns_D1_D0_D1_RK2(array, pattern, replacement, iseq) result(arrayNew)
    3303             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3304             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_RK2
    3305             : #endif
    3306             :         use pm_kind, only: RKC => RK2
    3307             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    3308             :         real(RKC)               , intent(in)                    :: pattern
    3309             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    3310             :        !procedure(iseq_D0_D0_RK2)                               :: iseq
    3311             :         procedure(logical(LK))                                  :: iseq
    3312             :         real(RKC)                               , allocatable   :: arrayNew(:)
    3313             :     end function
    3314             : 
    3315             : #endif
    3316             : 
    3317             : #if RK1_ENABLED
    3318             :     module function getReplacedCusComDefIns_D1_D0_D1_RK1(array, pattern, replacement, iseq) result(arrayNew)
    3319             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3320             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D0_D1_RK1
    3321             : #endif
    3322             :         use pm_kind, only: RKC => RK1
    3323             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    3324             :         real(RKC)               , intent(in)                    :: pattern
    3325             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    3326             :        !procedure(iseq_D0_D0_RK1)                               :: iseq
    3327             :         procedure(logical(LK))                                  :: iseq
    3328             :         real(RKC)                               , allocatable   :: arrayNew(:)
    3329             :     end function
    3330             : #endif
    3331             : 
    3332             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3333             : 
    3334             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3335             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3336             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3337             : 
    3338             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3339             : 
    3340             : #if SK5_ENABLED
    3341             :     module function getReplacedCusComDefIns_D1_D1_D0_SK5(array, pattern, replacement, iseq) result(arrayNew)
    3342             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3343             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_SK5
    3344             : #endif
    3345             :         use pm_kind, only: SKC => SK5
    3346             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3347             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    3348             :         character(*,SKC)        , intent(in)                    :: replacement
    3349             :        !procedure(iseq_D1_D1_SK5)                               :: iseq
    3350             :         procedure(logical(LK))                                  :: iseq
    3351             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3352             :     end function
    3353             : #endif
    3354             : 
    3355             : #if SK4_ENABLED
    3356             :     module function getReplacedCusComDefIns_D1_D1_D0_SK4(array, pattern, replacement, iseq) result(arrayNew)
    3357             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3358             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_SK4
    3359             : #endif
    3360             :         use pm_kind, only: SKC => SK4
    3361             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3362             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    3363             :         character(*,SKC)        , intent(in)                    :: replacement
    3364             :        !procedure(iseq_D1_D1_SK4)                               :: iseq
    3365             :         procedure(logical(LK))                                  :: iseq
    3366             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3367             :     end function
    3368             : #endif
    3369             : 
    3370             : #if SK3_ENABLED
    3371             :     module function getReplacedCusComDefIns_D1_D1_D0_SK3(array, pattern, replacement, iseq) result(arrayNew)
    3372             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3373             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_SK3
    3374             : #endif
    3375             :         use pm_kind, only: SKC => SK3
    3376             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3377             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    3378             :         character(*,SKC)        , intent(in)                    :: replacement
    3379             :        !procedure(iseq_D1_D1_SK3)                               :: iseq
    3380             :         procedure(logical(LK))                                  :: iseq
    3381             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3382             :     end function
    3383             : #endif
    3384             : 
    3385             : #if SK2_ENABLED
    3386             :     module function getReplacedCusComDefIns_D1_D1_D0_SK2(array, pattern, replacement, iseq) result(arrayNew)
    3387             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3388             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_SK2
    3389             : #endif
    3390             :         use pm_kind, only: SKC => SK2
    3391             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3392             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    3393             :         character(*,SKC)        , intent(in)                    :: replacement
    3394             :        !procedure(iseq_D1_D1_SK2)                               :: iseq
    3395             :         procedure(logical(LK))                                  :: iseq
    3396             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3397             :     end function
    3398             : 
    3399             : #endif
    3400             : 
    3401             : #if SK1_ENABLED
    3402             :     module function getReplacedCusComDefIns_D1_D1_D0_SK1(array, pattern, replacement, iseq) result(arrayNew)
    3403             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3404             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_SK1
    3405             : #endif
    3406             :         use pm_kind, only: SKC => SK1
    3407             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3408             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    3409             :         character(*,SKC)        , intent(in)                    :: replacement
    3410             :        !procedure(iseq_D1_D1_SK1)                               :: iseq
    3411             :         procedure(logical(LK))                                  :: iseq
    3412             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3413             :     end function
    3414             : #endif
    3415             : 
    3416             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3417             : 
    3418             : #if IK5_ENABLED
    3419             :     module function getReplacedCusComDefIns_D1_D1_D0_IK5(array, pattern, replacement, iseq) result(arrayNew)
    3420             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3421             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_IK5
    3422             : #endif
    3423             :         use pm_kind, only: IKC => IK5
    3424             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3425             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    3426             :         integer(IKC)            , intent(in)                    :: replacement
    3427             :        !procedure(iseq_D1_D1_IK5)                               :: iseq
    3428             :         procedure(logical(LK))                                  :: iseq
    3429             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3430             :     end function
    3431             : #endif
    3432             : 
    3433             : #if IK4_ENABLED
    3434             :     module function getReplacedCusComDefIns_D1_D1_D0_IK4(array, pattern, replacement, iseq) result(arrayNew)
    3435             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3436             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_IK4
    3437             : #endif
    3438             :         use pm_kind, only: IKC => IK4
    3439             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3440             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    3441             :         integer(IKC)            , intent(in)                    :: replacement
    3442             :        !procedure(iseq_D1_D1_IK4)                               :: iseq
    3443             :         procedure(logical(LK))                                  :: iseq
    3444             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3445             :     end function
    3446             : #endif
    3447             : 
    3448             : #if IK3_ENABLED
    3449             :     module function getReplacedCusComDefIns_D1_D1_D0_IK3(array, pattern, replacement, iseq) result(arrayNew)
    3450             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3451             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_IK3
    3452             : #endif
    3453             :         use pm_kind, only: IKC => IK3
    3454             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3455             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    3456             :         integer(IKC)            , intent(in)                    :: replacement
    3457             :        !procedure(iseq_D1_D1_IK3)                               :: iseq
    3458             :         procedure(logical(LK))                                  :: iseq
    3459             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3460             :     end function
    3461             : #endif
    3462             : 
    3463             : #if IK2_ENABLED
    3464             :     module function getReplacedCusComDefIns_D1_D1_D0_IK2(array, pattern, replacement, iseq) result(arrayNew)
    3465             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3466             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_IK2
    3467             : #endif
    3468             :         use pm_kind, only: IKC => IK2
    3469             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3470             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    3471             :         integer(IKC)            , intent(in)                    :: replacement
    3472             :        !procedure(iseq_D1_D1_IK2)                               :: iseq
    3473             :         procedure(logical(LK))                                  :: iseq
    3474             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3475             :     end function
    3476             : 
    3477             : #endif
    3478             : 
    3479             : #if IK1_ENABLED
    3480             :     module function getReplacedCusComDefIns_D1_D1_D0_IK1(array, pattern, replacement, iseq) result(arrayNew)
    3481             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3482             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_IK1
    3483             : #endif
    3484             :         use pm_kind, only: IKC => IK1
    3485             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3486             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    3487             :         integer(IKC)            , intent(in)                    :: replacement
    3488             :        !procedure(iseq_D1_D1_IK1)                               :: iseq
    3489             :         procedure(logical(LK))                                  :: iseq
    3490             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3491             :     end function
    3492             : #endif
    3493             : 
    3494             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3495             : 
    3496             : #if LK5_ENABLED
    3497             :     module function getReplacedCusComDefIns_D1_D1_D0_LK5(array, pattern, replacement, iseq) result(arrayNew)
    3498             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3499             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_LK5
    3500             : #endif
    3501             :         use pm_kind, only: LKC => LK5
    3502             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3503             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    3504             :         logical(LKC)            , intent(in)                    :: replacement
    3505             :        !procedure(iseq_D1_D1_LK5)                               :: iseq
    3506             :         procedure(logical(LK))                                  :: iseq
    3507             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3508             :     end function
    3509             : #endif
    3510             : 
    3511             : #if LK4_ENABLED
    3512             :     module function getReplacedCusComDefIns_D1_D1_D0_LK4(array, pattern, replacement, iseq) result(arrayNew)
    3513             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3514             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_LK4
    3515             : #endif
    3516             :         use pm_kind, only: LKC => LK4
    3517             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3518             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    3519             :         logical(LKC)            , intent(in)                    :: replacement
    3520             :        !procedure(iseq_D1_D1_LK4)                               :: iseq
    3521             :         procedure(logical(LK))                                  :: iseq
    3522             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3523             :     end function
    3524             : #endif
    3525             : 
    3526             : #if LK3_ENABLED
    3527             :     module function getReplacedCusComDefIns_D1_D1_D0_LK3(array, pattern, replacement, iseq) result(arrayNew)
    3528             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3529             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_LK3
    3530             : #endif
    3531             :         use pm_kind, only: LKC => LK3
    3532             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3533             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    3534             :         logical(LKC)            , intent(in)                    :: replacement
    3535             :        !procedure(iseq_D1_D1_LK3)                               :: iseq
    3536             :         procedure(logical(LK))                                  :: iseq
    3537             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3538             :     end function
    3539             : #endif
    3540             : 
    3541             : #if LK2_ENABLED
    3542             :     module function getReplacedCusComDefIns_D1_D1_D0_LK2(array, pattern, replacement, iseq) result(arrayNew)
    3543             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3544             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_LK2
    3545             : #endif
    3546             :         use pm_kind, only: LKC => LK2
    3547             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3548             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    3549             :         logical(LKC)            , intent(in)                    :: replacement
    3550             :        !procedure(iseq_D1_D1_LK2)                               :: iseq
    3551             :         procedure(logical(LK))                                  :: iseq
    3552             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3553             :     end function
    3554             : 
    3555             : #endif
    3556             : 
    3557             : #if LK1_ENABLED
    3558             :     module function getReplacedCusComDefIns_D1_D1_D0_LK1(array, pattern, replacement, iseq) result(arrayNew)
    3559             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3560             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_LK1
    3561             : #endif
    3562             :         use pm_kind, only: LKC => LK1
    3563             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3564             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    3565             :         logical(LKC)            , intent(in)                    :: replacement
    3566             :        !procedure(iseq_D1_D1_LK1)                               :: iseq
    3567             :         procedure(logical(LK))                                  :: iseq
    3568             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3569             :     end function
    3570             : #endif
    3571             : 
    3572             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3573             : 
    3574             : #if CK5_ENABLED
    3575             :     module function getReplacedCusComDefIns_D1_D1_D0_CK5(array, pattern, replacement, iseq) result(arrayNew)
    3576             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3577             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_CK5
    3578             : #endif
    3579             :         use pm_kind, only: CKC => CK5
    3580             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3581             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    3582             :         complex(CKC)            , intent(in)                    :: replacement
    3583             :        !procedure(iseq_D1_D1_CK5)                               :: iseq
    3584             :         procedure(logical(LK))                                  :: iseq
    3585             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3586             :     end function
    3587             : #endif
    3588             : 
    3589             : #if CK4_ENABLED
    3590             :     module function getReplacedCusComDefIns_D1_D1_D0_CK4(array, pattern, replacement, iseq) result(arrayNew)
    3591             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3592             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_CK4
    3593             : #endif
    3594             :         use pm_kind, only: CKC => CK4
    3595             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3596             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    3597             :         complex(CKC)            , intent(in)                    :: replacement
    3598             :        !procedure(iseq_D1_D1_CK4)                               :: iseq
    3599             :         procedure(logical(LK))                                  :: iseq
    3600             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3601             :     end function
    3602             : #endif
    3603             : 
    3604             : #if CK3_ENABLED
    3605             :     module function getReplacedCusComDefIns_D1_D1_D0_CK3(array, pattern, replacement, iseq) result(arrayNew)
    3606             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3607             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_CK3
    3608             : #endif
    3609             :         use pm_kind, only: CKC => CK3
    3610             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3611             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    3612             :         complex(CKC)            , intent(in)                    :: replacement
    3613             :        !procedure(iseq_D1_D1_CK3)                               :: iseq
    3614             :         procedure(logical(LK))                                  :: iseq
    3615             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3616             :     end function
    3617             : #endif
    3618             : 
    3619             : #if CK2_ENABLED
    3620             :     module function getReplacedCusComDefIns_D1_D1_D0_CK2(array, pattern, replacement, iseq) result(arrayNew)
    3621             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3622             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_CK2
    3623             : #endif
    3624             :         use pm_kind, only: CKC => CK2
    3625             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3626             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    3627             :         complex(CKC)            , intent(in)                    :: replacement
    3628             :        !procedure(iseq_D1_D1_CK2)                               :: iseq
    3629             :         procedure(logical(LK))                                  :: iseq
    3630             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3631             :     end function
    3632             : 
    3633             : #endif
    3634             : 
    3635             : #if CK1_ENABLED
    3636             :     module function getReplacedCusComDefIns_D1_D1_D0_CK1(array, pattern, replacement, iseq) result(arrayNew)
    3637             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3638             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_CK1
    3639             : #endif
    3640             :         use pm_kind, only: CKC => CK1
    3641             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3642             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    3643             :         complex(CKC)            , intent(in)                    :: replacement
    3644             :        !procedure(iseq_D1_D1_CK1)                               :: iseq
    3645             :         procedure(logical(LK))                                  :: iseq
    3646             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3647             :     end function
    3648             : #endif
    3649             : 
    3650             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3651             : 
    3652             : #if RK5_ENABLED
    3653             :     module function getReplacedCusComDefIns_D1_D1_D0_RK5(array, pattern, replacement, iseq) result(arrayNew)
    3654             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3655             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_RK5
    3656             : #endif
    3657             :         use pm_kind, only: RKC => RK5
    3658             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    3659             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    3660             :         real(RKC)               , intent(in)                    :: replacement
    3661             :        !procedure(iseq_D1_D1_RK5)                               :: iseq
    3662             :         procedure(logical(LK))                                  :: iseq
    3663             :         real(RKC)                               , allocatable   :: arrayNew(:)
    3664             :     end function
    3665             : #endif
    3666             : 
    3667             : #if RK4_ENABLED
    3668             :     module function getReplacedCusComDefIns_D1_D1_D0_RK4(array, pattern, replacement, iseq) result(arrayNew)
    3669             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3670             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_RK4
    3671             : #endif
    3672             :         use pm_kind, only: RKC => RK4
    3673             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    3674             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    3675             :         real(RKC)               , intent(in)                    :: replacement
    3676             :        !procedure(iseq_D1_D1_RK4)                               :: iseq
    3677             :         procedure(logical(LK))                                  :: iseq
    3678             :         real(RKC)                               , allocatable   :: arrayNew(:)
    3679             :     end function
    3680             : #endif
    3681             : 
    3682             : #if RK3_ENABLED
    3683             :     module function getReplacedCusComDefIns_D1_D1_D0_RK3(array, pattern, replacement, iseq) result(arrayNew)
    3684             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3685             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_RK3
    3686             : #endif
    3687             :         use pm_kind, only: RKC => RK3
    3688             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    3689             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    3690             :         real(RKC)               , intent(in)                    :: replacement
    3691             :        !procedure(iseq_D1_D1_RK3)                               :: iseq
    3692             :         procedure(logical(LK))                                  :: iseq
    3693             :         real(RKC)                               , allocatable   :: arrayNew(:)
    3694             :     end function
    3695             : #endif
    3696             : 
    3697             : #if RK2_ENABLED
    3698             :     module function getReplacedCusComDefIns_D1_D1_D0_RK2(array, pattern, replacement, iseq) result(arrayNew)
    3699             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3700             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_RK2
    3701             : #endif
    3702             :         use pm_kind, only: RKC => RK2
    3703             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    3704             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    3705             :         real(RKC)               , intent(in)                    :: replacement
    3706             :        !procedure(iseq_D1_D1_RK2)                               :: iseq
    3707             :         procedure(logical(LK))                                  :: iseq
    3708             :         real(RKC)                               , allocatable   :: arrayNew(:)
    3709             :     end function
    3710             : 
    3711             : #endif
    3712             : 
    3713             : #if RK1_ENABLED
    3714             :     module function getReplacedCusComDefIns_D1_D1_D0_RK1(array, pattern, replacement, iseq) result(arrayNew)
    3715             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3716             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D0_RK1
    3717             : #endif
    3718             :         use pm_kind, only: RKC => RK1
    3719             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    3720             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    3721             :         real(RKC)               , intent(in)                    :: replacement
    3722             :        !procedure(iseq_D1_D1_RK1)                               :: iseq
    3723             :         procedure(logical(LK))                                  :: iseq
    3724             :         real(RKC)                               , allocatable   :: arrayNew(:)
    3725             :     end function
    3726             : #endif
    3727             : 
    3728             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3729             : 
    3730             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3731             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3732             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3733             : 
    3734             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3735             : 
    3736             : #if SK5_ENABLED
    3737             :     module function getReplacedCusComDefIns_D1_D1_D1_SK5(array, pattern, replacement, iseq) result(arrayNew)
    3738             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3739             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_SK5
    3740             : #endif
    3741             :         use pm_kind, only: SKC => SK5
    3742             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3743             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    3744             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    3745             :        !procedure(iseq_D1_D1_SK5)                               :: iseq
    3746             :         procedure(logical(LK))                                  :: iseq
    3747             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3748             :     end function
    3749             : #endif
    3750             : 
    3751             : #if SK4_ENABLED
    3752             :     module function getReplacedCusComDefIns_D1_D1_D1_SK4(array, pattern, replacement, iseq) result(arrayNew)
    3753             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3754             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_SK4
    3755             : #endif
    3756             :         use pm_kind, only: SKC => SK4
    3757             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3758             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    3759             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    3760             :        !procedure(iseq_D1_D1_SK4)                               :: iseq
    3761             :         procedure(logical(LK))                                  :: iseq
    3762             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3763             :     end function
    3764             : #endif
    3765             : 
    3766             : #if SK3_ENABLED
    3767             :     module function getReplacedCusComDefIns_D1_D1_D1_SK3(array, pattern, replacement, iseq) result(arrayNew)
    3768             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3769             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_SK3
    3770             : #endif
    3771             :         use pm_kind, only: SKC => SK3
    3772             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3773             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    3774             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    3775             :        !procedure(iseq_D1_D1_SK3)                               :: iseq
    3776             :         procedure(logical(LK))                                  :: iseq
    3777             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3778             :     end function
    3779             : #endif
    3780             : 
    3781             : #if SK2_ENABLED
    3782             :     module function getReplacedCusComDefIns_D1_D1_D1_SK2(array, pattern, replacement, iseq) result(arrayNew)
    3783             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3784             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_SK2
    3785             : #endif
    3786             :         use pm_kind, only: SKC => SK2
    3787             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3788             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    3789             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    3790             :        !procedure(iseq_D1_D1_SK2)                               :: iseq
    3791             :         procedure(logical(LK))                                  :: iseq
    3792             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3793             :     end function
    3794             : 
    3795             : #endif
    3796             : 
    3797             : #if SK1_ENABLED
    3798             :     module function getReplacedCusComDefIns_D1_D1_D1_SK1(array, pattern, replacement, iseq) result(arrayNew)
    3799             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3800             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_SK1
    3801             : #endif
    3802             :         use pm_kind, only: SKC => SK1
    3803             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    3804             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    3805             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    3806             :        !procedure(iseq_D1_D1_SK1)                               :: iseq
    3807             :         procedure(logical(LK))                                  :: iseq
    3808             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    3809             :     end function
    3810             : #endif
    3811             : 
    3812             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3813             : 
    3814             : #if IK5_ENABLED
    3815             :     module function getReplacedCusComDefIns_D1_D1_D1_IK5(array, pattern, replacement, iseq) result(arrayNew)
    3816             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3817             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_IK5
    3818             : #endif
    3819             :         use pm_kind, only: IKC => IK5
    3820             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3821             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    3822             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    3823             :        !procedure(iseq_D1_D1_IK5)                               :: iseq
    3824             :         procedure(logical(LK))                                  :: iseq
    3825             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3826             :     end function
    3827             : #endif
    3828             : 
    3829             : #if IK4_ENABLED
    3830             :     module function getReplacedCusComDefIns_D1_D1_D1_IK4(array, pattern, replacement, iseq) result(arrayNew)
    3831             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3832             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_IK4
    3833             : #endif
    3834             :         use pm_kind, only: IKC => IK4
    3835             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3836             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    3837             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    3838             :        !procedure(iseq_D1_D1_IK4)                               :: iseq
    3839             :         procedure(logical(LK))                                  :: iseq
    3840             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3841             :     end function
    3842             : #endif
    3843             : 
    3844             : #if IK3_ENABLED
    3845             :     module function getReplacedCusComDefIns_D1_D1_D1_IK3(array, pattern, replacement, iseq) result(arrayNew)
    3846             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3847             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_IK3
    3848             : #endif
    3849             :         use pm_kind, only: IKC => IK3
    3850             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3851             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    3852             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    3853             :        !procedure(iseq_D1_D1_IK3)                               :: iseq
    3854             :         procedure(logical(LK))                                  :: iseq
    3855             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3856             :     end function
    3857             : #endif
    3858             : 
    3859             : #if IK2_ENABLED
    3860             :     module function getReplacedCusComDefIns_D1_D1_D1_IK2(array, pattern, replacement, iseq) result(arrayNew)
    3861             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3862             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_IK2
    3863             : #endif
    3864             :         use pm_kind, only: IKC => IK2
    3865             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3866             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    3867             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    3868             :        !procedure(iseq_D1_D1_IK2)                               :: iseq
    3869             :         procedure(logical(LK))                                  :: iseq
    3870             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3871             :     end function
    3872             : 
    3873             : #endif
    3874             : 
    3875             : #if IK1_ENABLED
    3876             :     module function getReplacedCusComDefIns_D1_D1_D1_IK1(array, pattern, replacement, iseq) result(arrayNew)
    3877             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3878             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_IK1
    3879             : #endif
    3880             :         use pm_kind, only: IKC => IK1
    3881             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    3882             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    3883             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    3884             :        !procedure(iseq_D1_D1_IK1)                               :: iseq
    3885             :         procedure(logical(LK))                                  :: iseq
    3886             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    3887             :     end function
    3888             : #endif
    3889             : 
    3890             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3891             : 
    3892             : #if LK5_ENABLED
    3893             :     module function getReplacedCusComDefIns_D1_D1_D1_LK5(array, pattern, replacement, iseq) result(arrayNew)
    3894             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3895             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_LK5
    3896             : #endif
    3897             :         use pm_kind, only: LKC => LK5
    3898             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3899             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    3900             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    3901             :        !procedure(iseq_D1_D1_LK5)                               :: iseq
    3902             :         procedure(logical(LK))                                  :: iseq
    3903             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3904             :     end function
    3905             : #endif
    3906             : 
    3907             : #if LK4_ENABLED
    3908             :     module function getReplacedCusComDefIns_D1_D1_D1_LK4(array, pattern, replacement, iseq) result(arrayNew)
    3909             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3910             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_LK4
    3911             : #endif
    3912             :         use pm_kind, only: LKC => LK4
    3913             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3914             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    3915             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    3916             :        !procedure(iseq_D1_D1_LK4)                               :: iseq
    3917             :         procedure(logical(LK))                                  :: iseq
    3918             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3919             :     end function
    3920             : #endif
    3921             : 
    3922             : #if LK3_ENABLED
    3923             :     module function getReplacedCusComDefIns_D1_D1_D1_LK3(array, pattern, replacement, iseq) result(arrayNew)
    3924             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3925             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_LK3
    3926             : #endif
    3927             :         use pm_kind, only: LKC => LK3
    3928             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3929             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    3930             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    3931             :        !procedure(iseq_D1_D1_LK3)                               :: iseq
    3932             :         procedure(logical(LK))                                  :: iseq
    3933             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3934             :     end function
    3935             : #endif
    3936             : 
    3937             : #if LK2_ENABLED
    3938             :     module function getReplacedCusComDefIns_D1_D1_D1_LK2(array, pattern, replacement, iseq) result(arrayNew)
    3939             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3940             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_LK2
    3941             : #endif
    3942             :         use pm_kind, only: LKC => LK2
    3943             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3944             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    3945             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    3946             :        !procedure(iseq_D1_D1_LK2)                               :: iseq
    3947             :         procedure(logical(LK))                                  :: iseq
    3948             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3949             :     end function
    3950             : 
    3951             : #endif
    3952             : 
    3953             : #if LK1_ENABLED
    3954             :     module function getReplacedCusComDefIns_D1_D1_D1_LK1(array, pattern, replacement, iseq) result(arrayNew)
    3955             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3956             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_LK1
    3957             : #endif
    3958             :         use pm_kind, only: LKC => LK1
    3959             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    3960             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    3961             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    3962             :        !procedure(iseq_D1_D1_LK1)                               :: iseq
    3963             :         procedure(logical(LK))                                  :: iseq
    3964             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    3965             :     end function
    3966             : #endif
    3967             : 
    3968             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    3969             : 
    3970             : #if CK5_ENABLED
    3971             :     module function getReplacedCusComDefIns_D1_D1_D1_CK5(array, pattern, replacement, iseq) result(arrayNew)
    3972             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3973             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_CK5
    3974             : #endif
    3975             :         use pm_kind, only: CKC => CK5
    3976             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3977             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    3978             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    3979             :        !procedure(iseq_D1_D1_CK5)                               :: iseq
    3980             :         procedure(logical(LK))                                  :: iseq
    3981             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3982             :     end function
    3983             : #endif
    3984             : 
    3985             : #if CK4_ENABLED
    3986             :     module function getReplacedCusComDefIns_D1_D1_D1_CK4(array, pattern, replacement, iseq) result(arrayNew)
    3987             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    3988             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_CK4
    3989             : #endif
    3990             :         use pm_kind, only: CKC => CK4
    3991             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    3992             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    3993             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    3994             :        !procedure(iseq_D1_D1_CK4)                               :: iseq
    3995             :         procedure(logical(LK))                                  :: iseq
    3996             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    3997             :     end function
    3998             : #endif
    3999             : 
    4000             : #if CK3_ENABLED
    4001             :     module function getReplacedCusComDefIns_D1_D1_D1_CK3(array, pattern, replacement, iseq) result(arrayNew)
    4002             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4003             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_CK3
    4004             : #endif
    4005             :         use pm_kind, only: CKC => CK3
    4006             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4007             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    4008             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    4009             :        !procedure(iseq_D1_D1_CK3)                               :: iseq
    4010             :         procedure(logical(LK))                                  :: iseq
    4011             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4012             :     end function
    4013             : #endif
    4014             : 
    4015             : #if CK2_ENABLED
    4016             :     module function getReplacedCusComDefIns_D1_D1_D1_CK2(array, pattern, replacement, iseq) result(arrayNew)
    4017             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4018             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_CK2
    4019             : #endif
    4020             :         use pm_kind, only: CKC => CK2
    4021             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4022             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    4023             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    4024             :        !procedure(iseq_D1_D1_CK2)                               :: iseq
    4025             :         procedure(logical(LK))                                  :: iseq
    4026             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4027             :     end function
    4028             : 
    4029             : #endif
    4030             : 
    4031             : #if CK1_ENABLED
    4032             :     module function getReplacedCusComDefIns_D1_D1_D1_CK1(array, pattern, replacement, iseq) result(arrayNew)
    4033             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4034             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_CK1
    4035             : #endif
    4036             :         use pm_kind, only: CKC => CK1
    4037             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4038             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    4039             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    4040             :        !procedure(iseq_D1_D1_CK1)                               :: iseq
    4041             :         procedure(logical(LK))                                  :: iseq
    4042             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4043             :     end function
    4044             : #endif
    4045             : 
    4046             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4047             : 
    4048             : #if RK5_ENABLED
    4049             :     module function getReplacedCusComDefIns_D1_D1_D1_RK5(array, pattern, replacement, iseq) result(arrayNew)
    4050             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4051             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_RK5
    4052             : #endif
    4053             :         use pm_kind, only: RKC => RK5
    4054             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4055             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    4056             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    4057             :        !procedure(iseq_D1_D1_RK5)                               :: iseq
    4058             :         procedure(logical(LK))                                  :: iseq
    4059             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4060             :     end function
    4061             : #endif
    4062             : 
    4063             : #if RK4_ENABLED
    4064             :     module function getReplacedCusComDefIns_D1_D1_D1_RK4(array, pattern, replacement, iseq) result(arrayNew)
    4065             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4066             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_RK4
    4067             : #endif
    4068             :         use pm_kind, only: RKC => RK4
    4069             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4070             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    4071             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    4072             :        !procedure(iseq_D1_D1_RK4)                               :: iseq
    4073             :         procedure(logical(LK))                                  :: iseq
    4074             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4075             :     end function
    4076             : #endif
    4077             : 
    4078             : #if RK3_ENABLED
    4079             :     module function getReplacedCusComDefIns_D1_D1_D1_RK3(array, pattern, replacement, iseq) result(arrayNew)
    4080             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4081             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_RK3
    4082             : #endif
    4083             :         use pm_kind, only: RKC => RK3
    4084             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4085             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    4086             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    4087             :        !procedure(iseq_D1_D1_RK3)                               :: iseq
    4088             :         procedure(logical(LK))                                  :: iseq
    4089             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4090             :     end function
    4091             : #endif
    4092             : 
    4093             : #if RK2_ENABLED
    4094             :     module function getReplacedCusComDefIns_D1_D1_D1_RK2(array, pattern, replacement, iseq) result(arrayNew)
    4095             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4096             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_RK2
    4097             : #endif
    4098             :         use pm_kind, only: RKC => RK2
    4099             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4100             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    4101             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    4102             :        !procedure(iseq_D1_D1_RK2)                               :: iseq
    4103             :         procedure(logical(LK))                                  :: iseq
    4104             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4105             :     end function
    4106             : 
    4107             : #endif
    4108             : 
    4109             : #if RK1_ENABLED
    4110             :     module function getReplacedCusComDefIns_D1_D1_D1_RK1(array, pattern, replacement, iseq) result(arrayNew)
    4111             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4112             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComDefIns_D1_D1_D1_RK1
    4113             : #endif
    4114             :         use pm_kind, only: RKC => RK1
    4115             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4116             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    4117             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    4118             :        !procedure(iseq_D1_D1_RK1)                               :: iseq
    4119             :         procedure(logical(LK))                                  :: iseq
    4120             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4121             :     end function
    4122             : #endif
    4123             : 
    4124             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4125             : 
    4126             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4127             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4128             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4129             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4130             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4131             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4132             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4133             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4134             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4135             : 
    4136             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4137             : 
    4138             : #if SK5_ENABLED
    4139             :     PURE module function getReplacedDefComCusIns_D0_D0_D0_SK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4140             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4141             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D0_D0_D0_SK5
    4142             : #endif
    4143             :         use pm_kind, only: SKC => SK5
    4144             :         character(*,SKC)        , intent(in)                    :: array
    4145             :         character(*,SKC)        , intent(in)                    :: pattern
    4146             :         character(*,SKC)        , intent(in)                    :: replacement
    4147             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4148             :         logical(LK)             , intent(in)    , optional      :: sorted
    4149             :         logical(LK)             , intent(in)    , optional      :: unique
    4150             :         character(:,SKC)                        , allocatable   :: arrayNew
    4151             :     end function
    4152             : #endif
    4153             : 
    4154             : #if SK4_ENABLED
    4155             :     PURE module function getReplacedDefComCusIns_D0_D0_D0_SK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4156             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4157             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D0_D0_D0_SK4
    4158             : #endif
    4159             :         use pm_kind, only: SKC => SK4
    4160             :         character(*,SKC)        , intent(in)                    :: array
    4161             :         character(*,SKC)        , intent(in)                    :: pattern
    4162             :         character(*,SKC)        , intent(in)                    :: replacement
    4163             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4164             :         logical(LK)             , intent(in)    , optional      :: sorted
    4165             :         logical(LK)             , intent(in)    , optional      :: unique
    4166             :         character(:,SKC)                        , allocatable   :: arrayNew
    4167             :     end function
    4168             : #endif
    4169             : 
    4170             : #if SK3_ENABLED
    4171             :     PURE module function getReplacedDefComCusIns_D0_D0_D0_SK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4172             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4173             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D0_D0_D0_SK3
    4174             : #endif
    4175             :         use pm_kind, only: SKC => SK3
    4176             :         character(*,SKC)        , intent(in)                    :: array
    4177             :         character(*,SKC)        , intent(in)                    :: pattern
    4178             :         character(*,SKC)        , intent(in)                    :: replacement
    4179             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4180             :         logical(LK)             , intent(in)    , optional      :: sorted
    4181             :         logical(LK)             , intent(in)    , optional      :: unique
    4182             :         character(:,SKC)                        , allocatable   :: arrayNew
    4183             :     end function
    4184             : #endif
    4185             : 
    4186             : #if SK2_ENABLED
    4187             :     PURE module function getReplacedDefComCusIns_D0_D0_D0_SK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4188             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4189             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D0_D0_D0_SK2
    4190             : #endif
    4191             :         use pm_kind, only: SKC => SK2
    4192             :         character(*,SKC)        , intent(in)                    :: array
    4193             :         character(*,SKC)        , intent(in)                    :: pattern
    4194             :         character(*,SKC)        , intent(in)                    :: replacement
    4195             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4196             :         logical(LK)             , intent(in)    , optional      :: sorted
    4197             :         logical(LK)             , intent(in)    , optional      :: unique
    4198             :         character(:,SKC)                        , allocatable   :: arrayNew
    4199             :     end function
    4200             : 
    4201             : #endif
    4202             : 
    4203             : #if SK1_ENABLED
    4204             :     PURE module function getReplacedDefComCusIns_D0_D0_D0_SK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4205             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4206             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D0_D0_D0_SK1
    4207             : #endif
    4208             :         use pm_kind, only: SKC => SK1
    4209             :         character(*,SKC)        , intent(in)                    :: array
    4210             :         character(*,SKC)        , intent(in)                    :: pattern
    4211             :         character(*,SKC)        , intent(in)                    :: replacement
    4212             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4213             :         logical(LK)             , intent(in)    , optional      :: sorted
    4214             :         logical(LK)             , intent(in)    , optional      :: unique
    4215             :         character(:,SKC)                        , allocatable   :: arrayNew
    4216             :     end function
    4217             : #endif
    4218             : 
    4219             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4220             : 
    4221             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4222             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4223             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4224             : 
    4225             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4226             : 
    4227             : #if SK5_ENABLED
    4228             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_SK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4229             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4230             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_SK5
    4231             : #endif
    4232             :         use pm_kind, only: SKC => SK5
    4233             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    4234             :         character(*,SKC)        , intent(in)                    :: pattern
    4235             :         character(*,SKC)        , intent(in)                    :: replacement
    4236             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4237             :         logical(LK)             , intent(in)    , optional      :: sorted
    4238             :         logical(LK)             , intent(in)    , optional      :: unique
    4239             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    4240             :     end function
    4241             : #endif
    4242             : 
    4243             : #if SK4_ENABLED
    4244             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_SK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4245             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4246             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_SK4
    4247             : #endif
    4248             :         use pm_kind, only: SKC => SK4
    4249             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    4250             :         character(*,SKC)        , intent(in)                    :: pattern
    4251             :         character(*,SKC)        , intent(in)                    :: replacement
    4252             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4253             :         logical(LK)             , intent(in)    , optional      :: sorted
    4254             :         logical(LK)             , intent(in)    , optional      :: unique
    4255             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    4256             :     end function
    4257             : #endif
    4258             : 
    4259             : #if SK3_ENABLED
    4260             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_SK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4261             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4262             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_SK3
    4263             : #endif
    4264             :         use pm_kind, only: SKC => SK3
    4265             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    4266             :         character(*,SKC)        , intent(in)                    :: pattern
    4267             :         character(*,SKC)        , intent(in)                    :: replacement
    4268             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4269             :         logical(LK)             , intent(in)    , optional      :: sorted
    4270             :         logical(LK)             , intent(in)    , optional      :: unique
    4271             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    4272             :     end function
    4273             : #endif
    4274             : 
    4275             : #if SK2_ENABLED
    4276             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_SK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4277             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4278             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_SK2
    4279             : #endif
    4280             :         use pm_kind, only: SKC => SK2
    4281             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    4282             :         character(*,SKC)        , intent(in)                    :: pattern
    4283             :         character(*,SKC)        , intent(in)                    :: replacement
    4284             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4285             :         logical(LK)             , intent(in)    , optional      :: sorted
    4286             :         logical(LK)             , intent(in)    , optional      :: unique
    4287             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    4288             :     end function
    4289             : 
    4290             : #endif
    4291             : 
    4292             : #if SK1_ENABLED
    4293             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_SK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4294             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4295             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_SK1
    4296             : #endif
    4297             :         use pm_kind, only: SKC => SK1
    4298             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    4299             :         character(*,SKC)        , intent(in)                    :: pattern
    4300             :         character(*,SKC)        , intent(in)                    :: replacement
    4301             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4302             :         logical(LK)             , intent(in)    , optional      :: sorted
    4303             :         logical(LK)             , intent(in)    , optional      :: unique
    4304             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    4305             :     end function
    4306             : #endif
    4307             : 
    4308             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4309             : 
    4310             : #if IK5_ENABLED
    4311             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_IK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4312             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4313             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_IK5
    4314             : #endif
    4315             :         use pm_kind, only: IKC => IK5
    4316             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    4317             :         integer(IKC)            , intent(in)                    :: pattern
    4318             :         integer(IKC)            , intent(in)                    :: replacement
    4319             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4320             :         logical(LK)             , intent(in)    , optional      :: sorted
    4321             :         logical(LK)             , intent(in)    , optional      :: unique
    4322             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    4323             :     end function
    4324             : #endif
    4325             : 
    4326             : #if IK4_ENABLED
    4327             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_IK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4328             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4329             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_IK4
    4330             : #endif
    4331             :         use pm_kind, only: IKC => IK4
    4332             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    4333             :         integer(IKC)            , intent(in)                    :: pattern
    4334             :         integer(IKC)            , intent(in)                    :: replacement
    4335             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4336             :         logical(LK)             , intent(in)    , optional      :: sorted
    4337             :         logical(LK)             , intent(in)    , optional      :: unique
    4338             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    4339             :     end function
    4340             : #endif
    4341             : 
    4342             : #if IK3_ENABLED
    4343             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_IK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4344             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4345             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_IK3
    4346             : #endif
    4347             :         use pm_kind, only: IKC => IK3
    4348             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    4349             :         integer(IKC)            , intent(in)                    :: pattern
    4350             :         integer(IKC)            , intent(in)                    :: replacement
    4351             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4352             :         logical(LK)             , intent(in)    , optional      :: sorted
    4353             :         logical(LK)             , intent(in)    , optional      :: unique
    4354             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    4355             :     end function
    4356             : #endif
    4357             : 
    4358             : #if IK2_ENABLED
    4359             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_IK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4360             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4361             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_IK2
    4362             : #endif
    4363             :         use pm_kind, only: IKC => IK2
    4364             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    4365             :         integer(IKC)            , intent(in)                    :: pattern
    4366             :         integer(IKC)            , intent(in)                    :: replacement
    4367             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4368             :         logical(LK)             , intent(in)    , optional      :: sorted
    4369             :         logical(LK)             , intent(in)    , optional      :: unique
    4370             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    4371             :     end function
    4372             : 
    4373             : #endif
    4374             : 
    4375             : #if IK1_ENABLED
    4376             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_IK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4377             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4378             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_IK1
    4379             : #endif
    4380             :         use pm_kind, only: IKC => IK1
    4381             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    4382             :         integer(IKC)            , intent(in)                    :: pattern
    4383             :         integer(IKC)            , intent(in)                    :: replacement
    4384             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4385             :         logical(LK)             , intent(in)    , optional      :: sorted
    4386             :         logical(LK)             , intent(in)    , optional      :: unique
    4387             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    4388             :     end function
    4389             : #endif
    4390             : 
    4391             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4392             : 
    4393             : #if LK5_ENABLED
    4394             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_LK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4395             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4396             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_LK5
    4397             : #endif
    4398             :         use pm_kind, only: LKC => LK5
    4399             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    4400             :         logical(LKC)            , intent(in)                    :: pattern
    4401             :         logical(LKC)            , intent(in)                    :: replacement
    4402             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4403             :         logical(LK)             , intent(in)    , optional      :: sorted
    4404             :         logical(LK)             , intent(in)    , optional      :: unique
    4405             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    4406             :     end function
    4407             : #endif
    4408             : 
    4409             : #if LK4_ENABLED
    4410             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_LK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4411             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4412             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_LK4
    4413             : #endif
    4414             :         use pm_kind, only: LKC => LK4
    4415             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    4416             :         logical(LKC)            , intent(in)                    :: pattern
    4417             :         logical(LKC)            , intent(in)                    :: replacement
    4418             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4419             :         logical(LK)             , intent(in)    , optional      :: sorted
    4420             :         logical(LK)             , intent(in)    , optional      :: unique
    4421             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    4422             :     end function
    4423             : #endif
    4424             : 
    4425             : #if LK3_ENABLED
    4426             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_LK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4427             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4428             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_LK3
    4429             : #endif
    4430             :         use pm_kind, only: LKC => LK3
    4431             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    4432             :         logical(LKC)            , intent(in)                    :: pattern
    4433             :         logical(LKC)            , intent(in)                    :: replacement
    4434             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4435             :         logical(LK)             , intent(in)    , optional      :: sorted
    4436             :         logical(LK)             , intent(in)    , optional      :: unique
    4437             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    4438             :     end function
    4439             : #endif
    4440             : 
    4441             : #if LK2_ENABLED
    4442             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_LK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4443             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4444             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_LK2
    4445             : #endif
    4446             :         use pm_kind, only: LKC => LK2
    4447             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    4448             :         logical(LKC)            , intent(in)                    :: pattern
    4449             :         logical(LKC)            , intent(in)                    :: replacement
    4450             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4451             :         logical(LK)             , intent(in)    , optional      :: sorted
    4452             :         logical(LK)             , intent(in)    , optional      :: unique
    4453             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    4454             :     end function
    4455             : 
    4456             : #endif
    4457             : 
    4458             : #if LK1_ENABLED
    4459             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_LK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4460             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4461             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_LK1
    4462             : #endif
    4463             :         use pm_kind, only: LKC => LK1
    4464             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    4465             :         logical(LKC)            , intent(in)                    :: pattern
    4466             :         logical(LKC)            , intent(in)                    :: replacement
    4467             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4468             :         logical(LK)             , intent(in)    , optional      :: sorted
    4469             :         logical(LK)             , intent(in)    , optional      :: unique
    4470             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    4471             :     end function
    4472             : #endif
    4473             : 
    4474             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4475             : 
    4476             : #if CK5_ENABLED
    4477             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_CK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4478             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4479             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_CK5
    4480             : #endif
    4481             :         use pm_kind, only: CKC => CK5
    4482             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4483             :         complex(CKC)            , intent(in)                    :: pattern
    4484             :         complex(CKC)            , intent(in)                    :: replacement
    4485             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4486             :         logical(LK)             , intent(in)    , optional      :: sorted
    4487             :         logical(LK)             , intent(in)    , optional      :: unique
    4488             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4489             :     end function
    4490             : #endif
    4491             : 
    4492             : #if CK4_ENABLED
    4493             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_CK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4494             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4495             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_CK4
    4496             : #endif
    4497             :         use pm_kind, only: CKC => CK4
    4498             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4499             :         complex(CKC)            , intent(in)                    :: pattern
    4500             :         complex(CKC)            , intent(in)                    :: replacement
    4501             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4502             :         logical(LK)             , intent(in)    , optional      :: sorted
    4503             :         logical(LK)             , intent(in)    , optional      :: unique
    4504             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4505             :     end function
    4506             : #endif
    4507             : 
    4508             : #if CK3_ENABLED
    4509             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_CK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4510             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4511             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_CK3
    4512             : #endif
    4513             :         use pm_kind, only: CKC => CK3
    4514             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4515             :         complex(CKC)            , intent(in)                    :: pattern
    4516             :         complex(CKC)            , intent(in)                    :: replacement
    4517             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4518             :         logical(LK)             , intent(in)    , optional      :: sorted
    4519             :         logical(LK)             , intent(in)    , optional      :: unique
    4520             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4521             :     end function
    4522             : #endif
    4523             : 
    4524             : #if CK2_ENABLED
    4525             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_CK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4526             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4527             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_CK2
    4528             : #endif
    4529             :         use pm_kind, only: CKC => CK2
    4530             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4531             :         complex(CKC)            , intent(in)                    :: pattern
    4532             :         complex(CKC)            , intent(in)                    :: replacement
    4533             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4534             :         logical(LK)             , intent(in)    , optional      :: sorted
    4535             :         logical(LK)             , intent(in)    , optional      :: unique
    4536             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4537             :     end function
    4538             : 
    4539             : #endif
    4540             : 
    4541             : #if CK1_ENABLED
    4542             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_CK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4543             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4544             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_CK1
    4545             : #endif
    4546             :         use pm_kind, only: CKC => CK1
    4547             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4548             :         complex(CKC)            , intent(in)                    :: pattern
    4549             :         complex(CKC)            , intent(in)                    :: replacement
    4550             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4551             :         logical(LK)             , intent(in)    , optional      :: sorted
    4552             :         logical(LK)             , intent(in)    , optional      :: unique
    4553             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4554             :     end function
    4555             : #endif
    4556             : 
    4557             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4558             : 
    4559             : #if RK5_ENABLED
    4560             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_RK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4561             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4562             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_RK5
    4563             : #endif
    4564             :         use pm_kind, only: RKC => RK5
    4565             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4566             :         real(RKC)               , intent(in)                    :: pattern
    4567             :         real(RKC)               , intent(in)                    :: replacement
    4568             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4569             :         logical(LK)             , intent(in)    , optional      :: sorted
    4570             :         logical(LK)             , intent(in)    , optional      :: unique
    4571             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4572             :     end function
    4573             : #endif
    4574             : 
    4575             : #if RK4_ENABLED
    4576             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_RK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4577             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4578             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_RK4
    4579             : #endif
    4580             :         use pm_kind, only: RKC => RK4
    4581             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4582             :         real(RKC)               , intent(in)                    :: pattern
    4583             :         real(RKC)               , intent(in)                    :: replacement
    4584             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4585             :         logical(LK)             , intent(in)    , optional      :: sorted
    4586             :         logical(LK)             , intent(in)    , optional      :: unique
    4587             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4588             :     end function
    4589             : #endif
    4590             : 
    4591             : #if RK3_ENABLED
    4592             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_RK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4593             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4594             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_RK3
    4595             : #endif
    4596             :         use pm_kind, only: RKC => RK3
    4597             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4598             :         real(RKC)               , intent(in)                    :: pattern
    4599             :         real(RKC)               , intent(in)                    :: replacement
    4600             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4601             :         logical(LK)             , intent(in)    , optional      :: sorted
    4602             :         logical(LK)             , intent(in)    , optional      :: unique
    4603             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4604             :     end function
    4605             : #endif
    4606             : 
    4607             : #if RK2_ENABLED
    4608             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_RK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4609             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4610             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_RK2
    4611             : #endif
    4612             :         use pm_kind, only: RKC => RK2
    4613             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4614             :         real(RKC)               , intent(in)                    :: pattern
    4615             :         real(RKC)               , intent(in)                    :: replacement
    4616             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4617             :         logical(LK)             , intent(in)    , optional      :: sorted
    4618             :         logical(LK)             , intent(in)    , optional      :: unique
    4619             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4620             :     end function
    4621             : 
    4622             : #endif
    4623             : 
    4624             : #if RK1_ENABLED
    4625             :     PURE module function getReplacedDefComCusIns_D1_D0_D0_RK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4626             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4627             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D0_RK1
    4628             : #endif
    4629             :         use pm_kind, only: RKC => RK1
    4630             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4631             :         real(RKC)               , intent(in)                    :: pattern
    4632             :         real(RKC)               , intent(in)                    :: replacement
    4633             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4634             :         logical(LK)             , intent(in)    , optional      :: sorted
    4635             :         logical(LK)             , intent(in)    , optional      :: unique
    4636             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4637             :     end function
    4638             : #endif
    4639             : 
    4640             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4641             : 
    4642             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4643             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4644             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4645             : 
    4646             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4647             : 
    4648             : #if SK5_ENABLED
    4649             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_SK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4650             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4651             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_SK5
    4652             : #endif
    4653             :         use pm_kind, only: SKC => SK5
    4654             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    4655             :         character(*,SKC)        , intent(in)                    :: pattern
    4656             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    4657             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4658             :         logical(LK)             , intent(in)    , optional      :: sorted
    4659             :         logical(LK)             , intent(in)    , optional      :: unique
    4660             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    4661             :     end function
    4662             : #endif
    4663             : 
    4664             : #if SK4_ENABLED
    4665             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_SK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4666             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4667             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_SK4
    4668             : #endif
    4669             :         use pm_kind, only: SKC => SK4
    4670             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    4671             :         character(*,SKC)        , intent(in)                    :: pattern
    4672             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    4673             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4674             :         logical(LK)             , intent(in)    , optional      :: sorted
    4675             :         logical(LK)             , intent(in)    , optional      :: unique
    4676             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    4677             :     end function
    4678             : #endif
    4679             : 
    4680             : #if SK3_ENABLED
    4681             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_SK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4682             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4683             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_SK3
    4684             : #endif
    4685             :         use pm_kind, only: SKC => SK3
    4686             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    4687             :         character(*,SKC)        , intent(in)                    :: pattern
    4688             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    4689             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4690             :         logical(LK)             , intent(in)    , optional      :: sorted
    4691             :         logical(LK)             , intent(in)    , optional      :: unique
    4692             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    4693             :     end function
    4694             : #endif
    4695             : 
    4696             : #if SK2_ENABLED
    4697             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_SK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4698             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4699             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_SK2
    4700             : #endif
    4701             :         use pm_kind, only: SKC => SK2
    4702             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    4703             :         character(*,SKC)        , intent(in)                    :: pattern
    4704             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    4705             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4706             :         logical(LK)             , intent(in)    , optional      :: sorted
    4707             :         logical(LK)             , intent(in)    , optional      :: unique
    4708             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    4709             :     end function
    4710             : 
    4711             : #endif
    4712             : 
    4713             : #if SK1_ENABLED
    4714             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_SK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4715             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4716             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_SK1
    4717             : #endif
    4718             :         use pm_kind, only: SKC => SK1
    4719             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    4720             :         character(*,SKC)        , intent(in)                    :: pattern
    4721             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    4722             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4723             :         logical(LK)             , intent(in)    , optional      :: sorted
    4724             :         logical(LK)             , intent(in)    , optional      :: unique
    4725             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    4726             :     end function
    4727             : #endif
    4728             : 
    4729             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4730             : 
    4731             : #if IK5_ENABLED
    4732             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_IK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4733             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4734             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_IK5
    4735             : #endif
    4736             :         use pm_kind, only: IKC => IK5
    4737             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    4738             :         integer(IKC)            , intent(in)                    :: pattern
    4739             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    4740             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4741             :         logical(LK)             , intent(in)    , optional      :: sorted
    4742             :         logical(LK)             , intent(in)    , optional      :: unique
    4743             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    4744             :     end function
    4745             : #endif
    4746             : 
    4747             : #if IK4_ENABLED
    4748             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_IK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4749             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4750             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_IK4
    4751             : #endif
    4752             :         use pm_kind, only: IKC => IK4
    4753             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    4754             :         integer(IKC)            , intent(in)                    :: pattern
    4755             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    4756             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4757             :         logical(LK)             , intent(in)    , optional      :: sorted
    4758             :         logical(LK)             , intent(in)    , optional      :: unique
    4759             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    4760             :     end function
    4761             : #endif
    4762             : 
    4763             : #if IK3_ENABLED
    4764             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_IK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4765             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4766             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_IK3
    4767             : #endif
    4768             :         use pm_kind, only: IKC => IK3
    4769             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    4770             :         integer(IKC)            , intent(in)                    :: pattern
    4771             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    4772             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4773             :         logical(LK)             , intent(in)    , optional      :: sorted
    4774             :         logical(LK)             , intent(in)    , optional      :: unique
    4775             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    4776             :     end function
    4777             : #endif
    4778             : 
    4779             : #if IK2_ENABLED
    4780             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_IK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4781             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4782             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_IK2
    4783             : #endif
    4784             :         use pm_kind, only: IKC => IK2
    4785             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    4786             :         integer(IKC)            , intent(in)                    :: pattern
    4787             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    4788             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4789             :         logical(LK)             , intent(in)    , optional      :: sorted
    4790             :         logical(LK)             , intent(in)    , optional      :: unique
    4791             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    4792             :     end function
    4793             : 
    4794             : #endif
    4795             : 
    4796             : #if IK1_ENABLED
    4797             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_IK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4798             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4799             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_IK1
    4800             : #endif
    4801             :         use pm_kind, only: IKC => IK1
    4802             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    4803             :         integer(IKC)            , intent(in)                    :: pattern
    4804             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    4805             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4806             :         logical(LK)             , intent(in)    , optional      :: sorted
    4807             :         logical(LK)             , intent(in)    , optional      :: unique
    4808             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    4809             :     end function
    4810             : #endif
    4811             : 
    4812             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4813             : 
    4814             : #if LK5_ENABLED
    4815             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_LK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4816             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4817             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_LK5
    4818             : #endif
    4819             :         use pm_kind, only: LKC => LK5
    4820             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    4821             :         logical(LKC)            , intent(in)                    :: pattern
    4822             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    4823             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4824             :         logical(LK)             , intent(in)    , optional      :: sorted
    4825             :         logical(LK)             , intent(in)    , optional      :: unique
    4826             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    4827             :     end function
    4828             : #endif
    4829             : 
    4830             : #if LK4_ENABLED
    4831             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_LK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4832             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4833             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_LK4
    4834             : #endif
    4835             :         use pm_kind, only: LKC => LK4
    4836             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    4837             :         logical(LKC)            , intent(in)                    :: pattern
    4838             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    4839             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4840             :         logical(LK)             , intent(in)    , optional      :: sorted
    4841             :         logical(LK)             , intent(in)    , optional      :: unique
    4842             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    4843             :     end function
    4844             : #endif
    4845             : 
    4846             : #if LK3_ENABLED
    4847             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_LK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4848             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4849             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_LK3
    4850             : #endif
    4851             :         use pm_kind, only: LKC => LK3
    4852             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    4853             :         logical(LKC)            , intent(in)                    :: pattern
    4854             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    4855             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4856             :         logical(LK)             , intent(in)    , optional      :: sorted
    4857             :         logical(LK)             , intent(in)    , optional      :: unique
    4858             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    4859             :     end function
    4860             : #endif
    4861             : 
    4862             : #if LK2_ENABLED
    4863             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_LK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4864             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4865             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_LK2
    4866             : #endif
    4867             :         use pm_kind, only: LKC => LK2
    4868             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    4869             :         logical(LKC)            , intent(in)                    :: pattern
    4870             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    4871             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4872             :         logical(LK)             , intent(in)    , optional      :: sorted
    4873             :         logical(LK)             , intent(in)    , optional      :: unique
    4874             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    4875             :     end function
    4876             : 
    4877             : #endif
    4878             : 
    4879             : #if LK1_ENABLED
    4880             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_LK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4881             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4882             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_LK1
    4883             : #endif
    4884             :         use pm_kind, only: LKC => LK1
    4885             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    4886             :         logical(LKC)            , intent(in)                    :: pattern
    4887             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    4888             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4889             :         logical(LK)             , intent(in)    , optional      :: sorted
    4890             :         logical(LK)             , intent(in)    , optional      :: unique
    4891             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    4892             :     end function
    4893             : #endif
    4894             : 
    4895             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4896             : 
    4897             : #if CK5_ENABLED
    4898             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_CK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4899             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4900             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_CK5
    4901             : #endif
    4902             :         use pm_kind, only: CKC => CK5
    4903             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4904             :         complex(CKC)            , intent(in)                    :: pattern
    4905             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    4906             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4907             :         logical(LK)             , intent(in)    , optional      :: sorted
    4908             :         logical(LK)             , intent(in)    , optional      :: unique
    4909             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4910             :     end function
    4911             : #endif
    4912             : 
    4913             : #if CK4_ENABLED
    4914             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_CK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4915             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4916             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_CK4
    4917             : #endif
    4918             :         use pm_kind, only: CKC => CK4
    4919             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4920             :         complex(CKC)            , intent(in)                    :: pattern
    4921             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    4922             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4923             :         logical(LK)             , intent(in)    , optional      :: sorted
    4924             :         logical(LK)             , intent(in)    , optional      :: unique
    4925             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4926             :     end function
    4927             : #endif
    4928             : 
    4929             : #if CK3_ENABLED
    4930             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_CK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4931             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4932             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_CK3
    4933             : #endif
    4934             :         use pm_kind, only: CKC => CK3
    4935             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4936             :         complex(CKC)            , intent(in)                    :: pattern
    4937             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    4938             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4939             :         logical(LK)             , intent(in)    , optional      :: sorted
    4940             :         logical(LK)             , intent(in)    , optional      :: unique
    4941             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4942             :     end function
    4943             : #endif
    4944             : 
    4945             : #if CK2_ENABLED
    4946             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_CK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4947             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4948             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_CK2
    4949             : #endif
    4950             :         use pm_kind, only: CKC => CK2
    4951             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4952             :         complex(CKC)            , intent(in)                    :: pattern
    4953             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    4954             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4955             :         logical(LK)             , intent(in)    , optional      :: sorted
    4956             :         logical(LK)             , intent(in)    , optional      :: unique
    4957             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4958             :     end function
    4959             : 
    4960             : #endif
    4961             : 
    4962             : #if CK1_ENABLED
    4963             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_CK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4964             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4965             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_CK1
    4966             : #endif
    4967             :         use pm_kind, only: CKC => CK1
    4968             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    4969             :         complex(CKC)            , intent(in)                    :: pattern
    4970             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    4971             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4972             :         logical(LK)             , intent(in)    , optional      :: sorted
    4973             :         logical(LK)             , intent(in)    , optional      :: unique
    4974             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    4975             :     end function
    4976             : #endif
    4977             : 
    4978             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    4979             : 
    4980             : #if RK5_ENABLED
    4981             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_RK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4982             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4983             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_RK5
    4984             : #endif
    4985             :         use pm_kind, only: RKC => RK5
    4986             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    4987             :         real(RKC)               , intent(in)                    :: pattern
    4988             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    4989             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    4990             :         logical(LK)             , intent(in)    , optional      :: sorted
    4991             :         logical(LK)             , intent(in)    , optional      :: unique
    4992             :         real(RKC)                               , allocatable   :: arrayNew(:)
    4993             :     end function
    4994             : #endif
    4995             : 
    4996             : #if RK4_ENABLED
    4997             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_RK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    4998             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    4999             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_RK4
    5000             : #endif
    5001             :         use pm_kind, only: RKC => RK4
    5002             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5003             :         real(RKC)               , intent(in)                    :: pattern
    5004             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    5005             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5006             :         logical(LK)             , intent(in)    , optional      :: sorted
    5007             :         logical(LK)             , intent(in)    , optional      :: unique
    5008             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5009             :     end function
    5010             : #endif
    5011             : 
    5012             : #if RK3_ENABLED
    5013             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_RK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5014             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5015             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_RK3
    5016             : #endif
    5017             :         use pm_kind, only: RKC => RK3
    5018             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5019             :         real(RKC)               , intent(in)                    :: pattern
    5020             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    5021             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5022             :         logical(LK)             , intent(in)    , optional      :: sorted
    5023             :         logical(LK)             , intent(in)    , optional      :: unique
    5024             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5025             :     end function
    5026             : #endif
    5027             : 
    5028             : #if RK2_ENABLED
    5029             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_RK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5030             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5031             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_RK2
    5032             : #endif
    5033             :         use pm_kind, only: RKC => RK2
    5034             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5035             :         real(RKC)               , intent(in)                    :: pattern
    5036             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    5037             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5038             :         logical(LK)             , intent(in)    , optional      :: sorted
    5039             :         logical(LK)             , intent(in)    , optional      :: unique
    5040             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5041             :     end function
    5042             : 
    5043             : #endif
    5044             : 
    5045             : #if RK1_ENABLED
    5046             :     PURE module function getReplacedDefComCusIns_D1_D0_D1_RK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5047             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5048             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D0_D1_RK1
    5049             : #endif
    5050             :         use pm_kind, only: RKC => RK1
    5051             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5052             :         real(RKC)               , intent(in)                    :: pattern
    5053             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    5054             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5055             :         logical(LK)             , intent(in)    , optional      :: sorted
    5056             :         logical(LK)             , intent(in)    , optional      :: unique
    5057             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5058             :     end function
    5059             : #endif
    5060             : 
    5061             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5062             : 
    5063             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5064             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5065             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5066             : 
    5067             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5068             : 
    5069             : #if SK5_ENABLED
    5070             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_SK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5071             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5072             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_SK5
    5073             : #endif
    5074             :         use pm_kind, only: SKC => SK5
    5075             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    5076             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    5077             :         character(*,SKC)        , intent(in)                    :: replacement
    5078             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5079             :         logical(LK)             , intent(in)    , optional      :: sorted
    5080             :         logical(LK)             , intent(in)    , optional      :: unique
    5081             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    5082             :     end function
    5083             : #endif
    5084             : 
    5085             : #if SK4_ENABLED
    5086             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_SK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5087             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5088             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_SK4
    5089             : #endif
    5090             :         use pm_kind, only: SKC => SK4
    5091             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    5092             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    5093             :         character(*,SKC)        , intent(in)                    :: replacement
    5094             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5095             :         logical(LK)             , intent(in)    , optional      :: sorted
    5096             :         logical(LK)             , intent(in)    , optional      :: unique
    5097             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    5098             :     end function
    5099             : #endif
    5100             : 
    5101             : #if SK3_ENABLED
    5102             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_SK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5103             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5104             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_SK3
    5105             : #endif
    5106             :         use pm_kind, only: SKC => SK3
    5107             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    5108             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    5109             :         character(*,SKC)        , intent(in)                    :: replacement
    5110             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5111             :         logical(LK)             , intent(in)    , optional      :: sorted
    5112             :         logical(LK)             , intent(in)    , optional      :: unique
    5113             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    5114             :     end function
    5115             : #endif
    5116             : 
    5117             : #if SK2_ENABLED
    5118             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_SK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5119             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5120             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_SK2
    5121             : #endif
    5122             :         use pm_kind, only: SKC => SK2
    5123             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    5124             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    5125             :         character(*,SKC)        , intent(in)                    :: replacement
    5126             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5127             :         logical(LK)             , intent(in)    , optional      :: sorted
    5128             :         logical(LK)             , intent(in)    , optional      :: unique
    5129             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    5130             :     end function
    5131             : 
    5132             : #endif
    5133             : 
    5134             : #if SK1_ENABLED
    5135             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_SK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5136             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5137             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_SK1
    5138             : #endif
    5139             :         use pm_kind, only: SKC => SK1
    5140             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    5141             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    5142             :         character(*,SKC)        , intent(in)                    :: replacement
    5143             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5144             :         logical(LK)             , intent(in)    , optional      :: sorted
    5145             :         logical(LK)             , intent(in)    , optional      :: unique
    5146             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    5147             :     end function
    5148             : #endif
    5149             : 
    5150             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5151             : 
    5152             : #if IK5_ENABLED
    5153             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_IK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5154             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5155             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_IK5
    5156             : #endif
    5157             :         use pm_kind, only: IKC => IK5
    5158             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    5159             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    5160             :         integer(IKC)            , intent(in)                    :: replacement
    5161             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5162             :         logical(LK)             , intent(in)    , optional      :: sorted
    5163             :         logical(LK)             , intent(in)    , optional      :: unique
    5164             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    5165             :     end function
    5166             : #endif
    5167             : 
    5168             : #if IK4_ENABLED
    5169             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_IK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5170             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5171             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_IK4
    5172             : #endif
    5173             :         use pm_kind, only: IKC => IK4
    5174             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    5175             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    5176             :         integer(IKC)            , intent(in)                    :: replacement
    5177             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5178             :         logical(LK)             , intent(in)    , optional      :: sorted
    5179             :         logical(LK)             , intent(in)    , optional      :: unique
    5180             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    5181             :     end function
    5182             : #endif
    5183             : 
    5184             : #if IK3_ENABLED
    5185             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_IK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5186             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5187             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_IK3
    5188             : #endif
    5189             :         use pm_kind, only: IKC => IK3
    5190             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    5191             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    5192             :         integer(IKC)            , intent(in)                    :: replacement
    5193             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5194             :         logical(LK)             , intent(in)    , optional      :: sorted
    5195             :         logical(LK)             , intent(in)    , optional      :: unique
    5196             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    5197             :     end function
    5198             : #endif
    5199             : 
    5200             : #if IK2_ENABLED
    5201             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_IK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5202             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5203             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_IK2
    5204             : #endif
    5205             :         use pm_kind, only: IKC => IK2
    5206             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    5207             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    5208             :         integer(IKC)            , intent(in)                    :: replacement
    5209             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5210             :         logical(LK)             , intent(in)    , optional      :: sorted
    5211             :         logical(LK)             , intent(in)    , optional      :: unique
    5212             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    5213             :     end function
    5214             : 
    5215             : #endif
    5216             : 
    5217             : #if IK1_ENABLED
    5218             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_IK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5219             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5220             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_IK1
    5221             : #endif
    5222             :         use pm_kind, only: IKC => IK1
    5223             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    5224             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    5225             :         integer(IKC)            , intent(in)                    :: replacement
    5226             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5227             :         logical(LK)             , intent(in)    , optional      :: sorted
    5228             :         logical(LK)             , intent(in)    , optional      :: unique
    5229             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    5230             :     end function
    5231             : #endif
    5232             : 
    5233             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5234             : 
    5235             : #if LK5_ENABLED
    5236             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_LK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5237             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5238             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_LK5
    5239             : #endif
    5240             :         use pm_kind, only: LKC => LK5
    5241             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    5242             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    5243             :         logical(LKC)            , intent(in)                    :: replacement
    5244             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5245             :         logical(LK)             , intent(in)    , optional      :: sorted
    5246             :         logical(LK)             , intent(in)    , optional      :: unique
    5247             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    5248             :     end function
    5249             : #endif
    5250             : 
    5251             : #if LK4_ENABLED
    5252             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_LK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5253             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5254             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_LK4
    5255             : #endif
    5256             :         use pm_kind, only: LKC => LK4
    5257             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    5258             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    5259             :         logical(LKC)            , intent(in)                    :: replacement
    5260             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5261             :         logical(LK)             , intent(in)    , optional      :: sorted
    5262             :         logical(LK)             , intent(in)    , optional      :: unique
    5263             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    5264             :     end function
    5265             : #endif
    5266             : 
    5267             : #if LK3_ENABLED
    5268             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_LK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5269             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5270             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_LK3
    5271             : #endif
    5272             :         use pm_kind, only: LKC => LK3
    5273             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    5274             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    5275             :         logical(LKC)            , intent(in)                    :: replacement
    5276             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5277             :         logical(LK)             , intent(in)    , optional      :: sorted
    5278             :         logical(LK)             , intent(in)    , optional      :: unique
    5279             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    5280             :     end function
    5281             : #endif
    5282             : 
    5283             : #if LK2_ENABLED
    5284             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_LK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5285             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5286             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_LK2
    5287             : #endif
    5288             :         use pm_kind, only: LKC => LK2
    5289             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    5290             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    5291             :         logical(LKC)            , intent(in)                    :: replacement
    5292             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5293             :         logical(LK)             , intent(in)    , optional      :: sorted
    5294             :         logical(LK)             , intent(in)    , optional      :: unique
    5295             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    5296             :     end function
    5297             : 
    5298             : #endif
    5299             : 
    5300             : #if LK1_ENABLED
    5301             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_LK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5302             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5303             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_LK1
    5304             : #endif
    5305             :         use pm_kind, only: LKC => LK1
    5306             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    5307             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    5308             :         logical(LKC)            , intent(in)                    :: replacement
    5309             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5310             :         logical(LK)             , intent(in)    , optional      :: sorted
    5311             :         logical(LK)             , intent(in)    , optional      :: unique
    5312             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    5313             :     end function
    5314             : #endif
    5315             : 
    5316             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5317             : 
    5318             : #if CK5_ENABLED
    5319             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_CK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5320             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5321             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_CK5
    5322             : #endif
    5323             :         use pm_kind, only: CKC => CK5
    5324             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    5325             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    5326             :         complex(CKC)            , intent(in)                    :: replacement
    5327             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5328             :         logical(LK)             , intent(in)    , optional      :: sorted
    5329             :         logical(LK)             , intent(in)    , optional      :: unique
    5330             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    5331             :     end function
    5332             : #endif
    5333             : 
    5334             : #if CK4_ENABLED
    5335             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_CK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5336             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5337             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_CK4
    5338             : #endif
    5339             :         use pm_kind, only: CKC => CK4
    5340             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    5341             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    5342             :         complex(CKC)            , intent(in)                    :: replacement
    5343             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5344             :         logical(LK)             , intent(in)    , optional      :: sorted
    5345             :         logical(LK)             , intent(in)    , optional      :: unique
    5346             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    5347             :     end function
    5348             : #endif
    5349             : 
    5350             : #if CK3_ENABLED
    5351             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_CK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5352             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5353             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_CK3
    5354             : #endif
    5355             :         use pm_kind, only: CKC => CK3
    5356             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    5357             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    5358             :         complex(CKC)            , intent(in)                    :: replacement
    5359             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5360             :         logical(LK)             , intent(in)    , optional      :: sorted
    5361             :         logical(LK)             , intent(in)    , optional      :: unique
    5362             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    5363             :     end function
    5364             : #endif
    5365             : 
    5366             : #if CK2_ENABLED
    5367             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_CK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5368             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5369             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_CK2
    5370             : #endif
    5371             :         use pm_kind, only: CKC => CK2
    5372             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    5373             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    5374             :         complex(CKC)            , intent(in)                    :: replacement
    5375             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5376             :         logical(LK)             , intent(in)    , optional      :: sorted
    5377             :         logical(LK)             , intent(in)    , optional      :: unique
    5378             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    5379             :     end function
    5380             : 
    5381             : #endif
    5382             : 
    5383             : #if CK1_ENABLED
    5384             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_CK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5385             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5386             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_CK1
    5387             : #endif
    5388             :         use pm_kind, only: CKC => CK1
    5389             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    5390             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    5391             :         complex(CKC)            , intent(in)                    :: replacement
    5392             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5393             :         logical(LK)             , intent(in)    , optional      :: sorted
    5394             :         logical(LK)             , intent(in)    , optional      :: unique
    5395             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    5396             :     end function
    5397             : #endif
    5398             : 
    5399             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5400             : 
    5401             : #if RK5_ENABLED
    5402             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_RK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5403             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5404             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_RK5
    5405             : #endif
    5406             :         use pm_kind, only: RKC => RK5
    5407             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5408             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    5409             :         real(RKC)               , intent(in)                    :: replacement
    5410             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5411             :         logical(LK)             , intent(in)    , optional      :: sorted
    5412             :         logical(LK)             , intent(in)    , optional      :: unique
    5413             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5414             :     end function
    5415             : #endif
    5416             : 
    5417             : #if RK4_ENABLED
    5418             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_RK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5419             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5420             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_RK4
    5421             : #endif
    5422             :         use pm_kind, only: RKC => RK4
    5423             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5424             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    5425             :         real(RKC)               , intent(in)                    :: replacement
    5426             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5427             :         logical(LK)             , intent(in)    , optional      :: sorted
    5428             :         logical(LK)             , intent(in)    , optional      :: unique
    5429             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5430             :     end function
    5431             : #endif
    5432             : 
    5433             : #if RK3_ENABLED
    5434             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_RK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5435             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5436             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_RK3
    5437             : #endif
    5438             :         use pm_kind, only: RKC => RK3
    5439             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5440             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    5441             :         real(RKC)               , intent(in)                    :: replacement
    5442             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5443             :         logical(LK)             , intent(in)    , optional      :: sorted
    5444             :         logical(LK)             , intent(in)    , optional      :: unique
    5445             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5446             :     end function
    5447             : #endif
    5448             : 
    5449             : #if RK2_ENABLED
    5450             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_RK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5451             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5452             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_RK2
    5453             : #endif
    5454             :         use pm_kind, only: RKC => RK2
    5455             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5456             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    5457             :         real(RKC)               , intent(in)                    :: replacement
    5458             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5459             :         logical(LK)             , intent(in)    , optional      :: sorted
    5460             :         logical(LK)             , intent(in)    , optional      :: unique
    5461             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5462             :     end function
    5463             : 
    5464             : #endif
    5465             : 
    5466             : #if RK1_ENABLED
    5467             :     PURE module function getReplacedDefComCusIns_D1_D1_D0_RK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5468             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5469             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D0_RK1
    5470             : #endif
    5471             :         use pm_kind, only: RKC => RK1
    5472             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5473             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    5474             :         real(RKC)               , intent(in)                    :: replacement
    5475             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5476             :         logical(LK)             , intent(in)    , optional      :: sorted
    5477             :         logical(LK)             , intent(in)    , optional      :: unique
    5478             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5479             :     end function
    5480             : #endif
    5481             : 
    5482             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5483             : 
    5484             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5485             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5486             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5487             : 
    5488             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5489             : 
    5490             : #if SK5_ENABLED
    5491             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_SK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5492             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5493             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_SK5
    5494             : #endif
    5495             :         use pm_kind, only: SKC => SK5
    5496             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    5497             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    5498             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    5499             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5500             :         logical(LK)             , intent(in)    , optional      :: sorted
    5501             :         logical(LK)             , intent(in)    , optional      :: unique
    5502             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    5503             :     end function
    5504             : #endif
    5505             : 
    5506             : #if SK4_ENABLED
    5507             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_SK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5508             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5509             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_SK4
    5510             : #endif
    5511             :         use pm_kind, only: SKC => SK4
    5512             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    5513             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    5514             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    5515             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5516             :         logical(LK)             , intent(in)    , optional      :: sorted
    5517             :         logical(LK)             , intent(in)    , optional      :: unique
    5518             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    5519             :     end function
    5520             : #endif
    5521             : 
    5522             : #if SK3_ENABLED
    5523             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_SK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5524             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5525             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_SK3
    5526             : #endif
    5527             :         use pm_kind, only: SKC => SK3
    5528             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    5529             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    5530             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    5531             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5532             :         logical(LK)             , intent(in)    , optional      :: sorted
    5533             :         logical(LK)             , intent(in)    , optional      :: unique
    5534             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    5535             :     end function
    5536             : #endif
    5537             : 
    5538             : #if SK2_ENABLED
    5539             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_SK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5540             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5541             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_SK2
    5542             : #endif
    5543             :         use pm_kind, only: SKC => SK2
    5544             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    5545             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    5546             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    5547             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5548             :         logical(LK)             , intent(in)    , optional      :: sorted
    5549             :         logical(LK)             , intent(in)    , optional      :: unique
    5550             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    5551             :     end function
    5552             : 
    5553             : #endif
    5554             : 
    5555             : #if SK1_ENABLED
    5556             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_SK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5557             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5558             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_SK1
    5559             : #endif
    5560             :         use pm_kind, only: SKC => SK1
    5561             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    5562             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    5563             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    5564             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5565             :         logical(LK)             , intent(in)    , optional      :: sorted
    5566             :         logical(LK)             , intent(in)    , optional      :: unique
    5567             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    5568             :     end function
    5569             : #endif
    5570             : 
    5571             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5572             : 
    5573             : #if IK5_ENABLED
    5574             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_IK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5575             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5576             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_IK5
    5577             : #endif
    5578             :         use pm_kind, only: IKC => IK5
    5579             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    5580             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    5581             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    5582             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5583             :         logical(LK)             , intent(in)    , optional      :: sorted
    5584             :         logical(LK)             , intent(in)    , optional      :: unique
    5585             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    5586             :     end function
    5587             : #endif
    5588             : 
    5589             : #if IK4_ENABLED
    5590             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_IK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5591             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5592             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_IK4
    5593             : #endif
    5594             :         use pm_kind, only: IKC => IK4
    5595             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    5596             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    5597             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    5598             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5599             :         logical(LK)             , intent(in)    , optional      :: sorted
    5600             :         logical(LK)             , intent(in)    , optional      :: unique
    5601             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    5602             :     end function
    5603             : #endif
    5604             : 
    5605             : #if IK3_ENABLED
    5606             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_IK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5607             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5608             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_IK3
    5609             : #endif
    5610             :         use pm_kind, only: IKC => IK3
    5611             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    5612             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    5613             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    5614             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5615             :         logical(LK)             , intent(in)    , optional      :: sorted
    5616             :         logical(LK)             , intent(in)    , optional      :: unique
    5617             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    5618             :     end function
    5619             : #endif
    5620             : 
    5621             : #if IK2_ENABLED
    5622             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_IK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5623             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5624             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_IK2
    5625             : #endif
    5626             :         use pm_kind, only: IKC => IK2
    5627             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    5628             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    5629             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    5630             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5631             :         logical(LK)             , intent(in)    , optional      :: sorted
    5632             :         logical(LK)             , intent(in)    , optional      :: unique
    5633             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    5634             :     end function
    5635             : 
    5636             : #endif
    5637             : 
    5638             : #if IK1_ENABLED
    5639             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_IK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5640             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5641             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_IK1
    5642             : #endif
    5643             :         use pm_kind, only: IKC => IK1
    5644             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    5645             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    5646             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    5647             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5648             :         logical(LK)             , intent(in)    , optional      :: sorted
    5649             :         logical(LK)             , intent(in)    , optional      :: unique
    5650             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    5651             :     end function
    5652             : #endif
    5653             : 
    5654             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5655             : 
    5656             : #if LK5_ENABLED
    5657             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_LK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5658             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5659             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_LK5
    5660             : #endif
    5661             :         use pm_kind, only: LKC => LK5
    5662             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    5663             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    5664             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    5665             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5666             :         logical(LK)             , intent(in)    , optional      :: sorted
    5667             :         logical(LK)             , intent(in)    , optional      :: unique
    5668             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    5669             :     end function
    5670             : #endif
    5671             : 
    5672             : #if LK4_ENABLED
    5673             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_LK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5674             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5675             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_LK4
    5676             : #endif
    5677             :         use pm_kind, only: LKC => LK4
    5678             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    5679             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    5680             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    5681             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5682             :         logical(LK)             , intent(in)    , optional      :: sorted
    5683             :         logical(LK)             , intent(in)    , optional      :: unique
    5684             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    5685             :     end function
    5686             : #endif
    5687             : 
    5688             : #if LK3_ENABLED
    5689             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_LK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5690             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5691             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_LK3
    5692             : #endif
    5693             :         use pm_kind, only: LKC => LK3
    5694             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    5695             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    5696             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    5697             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5698             :         logical(LK)             , intent(in)    , optional      :: sorted
    5699             :         logical(LK)             , intent(in)    , optional      :: unique
    5700             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    5701             :     end function
    5702             : #endif
    5703             : 
    5704             : #if LK2_ENABLED
    5705             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_LK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5706             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5707             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_LK2
    5708             : #endif
    5709             :         use pm_kind, only: LKC => LK2
    5710             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    5711             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    5712             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    5713             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5714             :         logical(LK)             , intent(in)    , optional      :: sorted
    5715             :         logical(LK)             , intent(in)    , optional      :: unique
    5716             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    5717             :     end function
    5718             : 
    5719             : #endif
    5720             : 
    5721             : #if LK1_ENABLED
    5722             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_LK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5723             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5724             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_LK1
    5725             : #endif
    5726             :         use pm_kind, only: LKC => LK1
    5727             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    5728             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    5729             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    5730             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5731             :         logical(LK)             , intent(in)    , optional      :: sorted
    5732             :         logical(LK)             , intent(in)    , optional      :: unique
    5733             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    5734             :     end function
    5735             : #endif
    5736             : 
    5737             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5738             : 
    5739             : #if CK5_ENABLED
    5740             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_CK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5741             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5742             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_CK5
    5743             : #endif
    5744             :         use pm_kind, only: CKC => CK5
    5745             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    5746             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    5747             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    5748             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5749             :         logical(LK)             , intent(in)    , optional      :: sorted
    5750             :         logical(LK)             , intent(in)    , optional      :: unique
    5751             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    5752             :     end function
    5753             : #endif
    5754             : 
    5755             : #if CK4_ENABLED
    5756             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_CK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5757             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5758             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_CK4
    5759             : #endif
    5760             :         use pm_kind, only: CKC => CK4
    5761             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    5762             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    5763             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    5764             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5765             :         logical(LK)             , intent(in)    , optional      :: sorted
    5766             :         logical(LK)             , intent(in)    , optional      :: unique
    5767             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    5768             :     end function
    5769             : #endif
    5770             : 
    5771             : #if CK3_ENABLED
    5772             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_CK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5773             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5774             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_CK3
    5775             : #endif
    5776             :         use pm_kind, only: CKC => CK3
    5777             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    5778             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    5779             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    5780             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5781             :         logical(LK)             , intent(in)    , optional      :: sorted
    5782             :         logical(LK)             , intent(in)    , optional      :: unique
    5783             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    5784             :     end function
    5785             : #endif
    5786             : 
    5787             : #if CK2_ENABLED
    5788             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_CK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5789             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5790             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_CK2
    5791             : #endif
    5792             :         use pm_kind, only: CKC => CK2
    5793             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    5794             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    5795             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    5796             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5797             :         logical(LK)             , intent(in)    , optional      :: sorted
    5798             :         logical(LK)             , intent(in)    , optional      :: unique
    5799             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    5800             :     end function
    5801             : 
    5802             : #endif
    5803             : 
    5804             : #if CK1_ENABLED
    5805             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_CK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5806             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5807             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_CK1
    5808             : #endif
    5809             :         use pm_kind, only: CKC => CK1
    5810             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    5811             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    5812             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    5813             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5814             :         logical(LK)             , intent(in)    , optional      :: sorted
    5815             :         logical(LK)             , intent(in)    , optional      :: unique
    5816             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    5817             :     end function
    5818             : #endif
    5819             : 
    5820             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5821             : 
    5822             : #if RK5_ENABLED
    5823             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_RK5(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5824             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5825             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_RK5
    5826             : #endif
    5827             :         use pm_kind, only: RKC => RK5
    5828             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5829             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    5830             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    5831             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5832             :         logical(LK)             , intent(in)    , optional      :: sorted
    5833             :         logical(LK)             , intent(in)    , optional      :: unique
    5834             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5835             :     end function
    5836             : #endif
    5837             : 
    5838             : #if RK4_ENABLED
    5839             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_RK4(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5840             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5841             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_RK4
    5842             : #endif
    5843             :         use pm_kind, only: RKC => RK4
    5844             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5845             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    5846             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    5847             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5848             :         logical(LK)             , intent(in)    , optional      :: sorted
    5849             :         logical(LK)             , intent(in)    , optional      :: unique
    5850             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5851             :     end function
    5852             : #endif
    5853             : 
    5854             : #if RK3_ENABLED
    5855             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_RK3(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5856             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5857             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_RK3
    5858             : #endif
    5859             :         use pm_kind, only: RKC => RK3
    5860             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5861             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    5862             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    5863             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5864             :         logical(LK)             , intent(in)    , optional      :: sorted
    5865             :         logical(LK)             , intent(in)    , optional      :: unique
    5866             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5867             :     end function
    5868             : #endif
    5869             : 
    5870             : #if RK2_ENABLED
    5871             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_RK2(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5872             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5873             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_RK2
    5874             : #endif
    5875             :         use pm_kind, only: RKC => RK2
    5876             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5877             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    5878             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    5879             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5880             :         logical(LK)             , intent(in)    , optional      :: sorted
    5881             :         logical(LK)             , intent(in)    , optional      :: unique
    5882             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5883             :     end function
    5884             : 
    5885             : #endif
    5886             : 
    5887             : #if RK1_ENABLED
    5888             :     PURE module function getReplacedDefComCusIns_D1_D1_D1_RK1(array, pattern, replacement, instance, sorted, unique) result(arrayNew)
    5889             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5890             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedDefComCusIns_D1_D1_D1_RK1
    5891             : #endif
    5892             :         use pm_kind, only: RKC => RK1
    5893             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    5894             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    5895             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    5896             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5897             :         logical(LK)             , intent(in)    , optional      :: sorted
    5898             :         logical(LK)             , intent(in)    , optional      :: unique
    5899             :         real(RKC)                               , allocatable   :: arrayNew(:)
    5900             :     end function
    5901             : #endif
    5902             : 
    5903             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5904             : 
    5905             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5906             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5907             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5908             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5909             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5910             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5911             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5912             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5913             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5914             : 
    5915             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    5916             : 
    5917             : #if SK5_ENABLED
    5918             :     module function getReplacedCusComCusIns_D0_D0_D0_SK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    5919             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5920             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D0_D0_D0_SK5
    5921             : #endif
    5922             :         use pm_kind, only: SKC => SK5
    5923             :         character(*,SKC)        , intent(in)                    :: array
    5924             :         character(*,SKC)        , intent(in)                    :: pattern
    5925             :         character(*,SKC)        , intent(in)                    :: replacement
    5926             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
    5927             :         procedure(logical(LK))                                  :: iseq
    5928             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5929             :         logical(LK)             , intent(in)    , optional      :: sorted
    5930             :         logical(LK)             , intent(in)    , optional      :: unique
    5931             :         character(:,SKC)                        , allocatable   :: arrayNew
    5932             :     end function
    5933             : #endif
    5934             : 
    5935             : #if SK4_ENABLED
    5936             :     module function getReplacedCusComCusIns_D0_D0_D0_SK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    5937             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5938             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D0_D0_D0_SK4
    5939             : #endif
    5940             :         use pm_kind, only: SKC => SK4
    5941             :         character(*,SKC)        , intent(in)                    :: array
    5942             :         character(*,SKC)        , intent(in)                    :: pattern
    5943             :         character(*,SKC)        , intent(in)                    :: replacement
    5944             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
    5945             :         procedure(logical(LK))                                  :: iseq
    5946             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5947             :         logical(LK)             , intent(in)    , optional      :: sorted
    5948             :         logical(LK)             , intent(in)    , optional      :: unique
    5949             :         character(:,SKC)                        , allocatable   :: arrayNew
    5950             :     end function
    5951             : #endif
    5952             : 
    5953             : #if SK3_ENABLED
    5954             :     module function getReplacedCusComCusIns_D0_D0_D0_SK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    5955             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5956             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D0_D0_D0_SK3
    5957             : #endif
    5958             :         use pm_kind, only: SKC => SK3
    5959             :         character(*,SKC)        , intent(in)                    :: array
    5960             :         character(*,SKC)        , intent(in)                    :: pattern
    5961             :         character(*,SKC)        , intent(in)                    :: replacement
    5962             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
    5963             :         procedure(logical(LK))                                  :: iseq
    5964             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5965             :         logical(LK)             , intent(in)    , optional      :: sorted
    5966             :         logical(LK)             , intent(in)    , optional      :: unique
    5967             :         character(:,SKC)                        , allocatable   :: arrayNew
    5968             :     end function
    5969             : #endif
    5970             : 
    5971             : #if SK2_ENABLED
    5972             :     module function getReplacedCusComCusIns_D0_D0_D0_SK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    5973             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5974             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D0_D0_D0_SK2
    5975             : #endif
    5976             :         use pm_kind, only: SKC => SK2
    5977             :         character(*,SKC)        , intent(in)                    :: array
    5978             :         character(*,SKC)        , intent(in)                    :: pattern
    5979             :         character(*,SKC)        , intent(in)                    :: replacement
    5980             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
    5981             :         procedure(logical(LK))                                  :: iseq
    5982             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    5983             :         logical(LK)             , intent(in)    , optional      :: sorted
    5984             :         logical(LK)             , intent(in)    , optional      :: unique
    5985             :         character(:,SKC)                        , allocatable   :: arrayNew
    5986             :     end function
    5987             : 
    5988             : #endif
    5989             : 
    5990             : #if SK1_ENABLED
    5991             :     module function getReplacedCusComCusIns_D0_D0_D0_SK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    5992             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    5993             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D0_D0_D0_SK1
    5994             : #endif
    5995             :         use pm_kind, only: SKC => SK1
    5996             :         character(*,SKC)        , intent(in)                    :: array
    5997             :         character(*,SKC)        , intent(in)                    :: pattern
    5998             :         character(*,SKC)        , intent(in)                    :: replacement
    5999             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
    6000             :         procedure(logical(LK))                                  :: iseq
    6001             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6002             :         logical(LK)             , intent(in)    , optional      :: sorted
    6003             :         logical(LK)             , intent(in)    , optional      :: unique
    6004             :         character(:,SKC)                        , allocatable   :: arrayNew
    6005             :     end function
    6006             : #endif
    6007             : 
    6008             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6009             : 
    6010             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6011             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6012             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6013             : 
    6014             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6015             : 
    6016             : #if SK5_ENABLED
    6017             :     module function getReplacedCusComCusIns_D1_D0_D0_SK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6018             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6019             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_SK5
    6020             : #endif
    6021             :         use pm_kind, only: SKC => SK5
    6022             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6023             :         character(*,SKC)        , intent(in)                    :: pattern
    6024             :         character(*,SKC)        , intent(in)                    :: replacement
    6025             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
    6026             :         procedure(logical(LK))                                  :: iseq
    6027             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6028             :         logical(LK)             , intent(in)    , optional      :: sorted
    6029             :         logical(LK)             , intent(in)    , optional      :: unique
    6030             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6031             :     end function
    6032             : #endif
    6033             : 
    6034             : #if SK4_ENABLED
    6035             :     module function getReplacedCusComCusIns_D1_D0_D0_SK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6036             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6037             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_SK4
    6038             : #endif
    6039             :         use pm_kind, only: SKC => SK4
    6040             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6041             :         character(*,SKC)        , intent(in)                    :: pattern
    6042             :         character(*,SKC)        , intent(in)                    :: replacement
    6043             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
    6044             :         procedure(logical(LK))                                  :: iseq
    6045             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6046             :         logical(LK)             , intent(in)    , optional      :: sorted
    6047             :         logical(LK)             , intent(in)    , optional      :: unique
    6048             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6049             :     end function
    6050             : #endif
    6051             : 
    6052             : #if SK3_ENABLED
    6053             :     module function getReplacedCusComCusIns_D1_D0_D0_SK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6054             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6055             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_SK3
    6056             : #endif
    6057             :         use pm_kind, only: SKC => SK3
    6058             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6059             :         character(*,SKC)        , intent(in)                    :: pattern
    6060             :         character(*,SKC)        , intent(in)                    :: replacement
    6061             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
    6062             :         procedure(logical(LK))                                  :: iseq
    6063             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6064             :         logical(LK)             , intent(in)    , optional      :: sorted
    6065             :         logical(LK)             , intent(in)    , optional      :: unique
    6066             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6067             :     end function
    6068             : #endif
    6069             : 
    6070             : #if SK2_ENABLED
    6071             :     module function getReplacedCusComCusIns_D1_D0_D0_SK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6072             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6073             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_SK2
    6074             : #endif
    6075             :         use pm_kind, only: SKC => SK2
    6076             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6077             :         character(*,SKC)        , intent(in)                    :: pattern
    6078             :         character(*,SKC)        , intent(in)                    :: replacement
    6079             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
    6080             :         procedure(logical(LK))                                  :: iseq
    6081             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6082             :         logical(LK)             , intent(in)    , optional      :: sorted
    6083             :         logical(LK)             , intent(in)    , optional      :: unique
    6084             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6085             :     end function
    6086             : 
    6087             : #endif
    6088             : 
    6089             : #if SK1_ENABLED
    6090             :     module function getReplacedCusComCusIns_D1_D0_D0_SK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6091             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6092             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_SK1
    6093             : #endif
    6094             :         use pm_kind, only: SKC => SK1
    6095             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6096             :         character(*,SKC)        , intent(in)                    :: pattern
    6097             :         character(*,SKC)        , intent(in)                    :: replacement
    6098             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
    6099             :         procedure(logical(LK))                                  :: iseq
    6100             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6101             :         logical(LK)             , intent(in)    , optional      :: sorted
    6102             :         logical(LK)             , intent(in)    , optional      :: unique
    6103             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6104             :     end function
    6105             : #endif
    6106             : 
    6107             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6108             : 
    6109             : #if IK5_ENABLED
    6110             :     module function getReplacedCusComCusIns_D1_D0_D0_IK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6111             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6112             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_IK5
    6113             : #endif
    6114             :         use pm_kind, only: IKC => IK5
    6115             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    6116             :         integer(IKC)            , intent(in)                    :: pattern
    6117             :         integer(IKC)            , intent(in)                    :: replacement
    6118             :        !procedure(iseq_D0_D0_IK5)                               :: iseq
    6119             :         procedure(logical(LK))                                  :: iseq
    6120             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6121             :         logical(LK)             , intent(in)    , optional      :: sorted
    6122             :         logical(LK)             , intent(in)    , optional      :: unique
    6123             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    6124             :     end function
    6125             : #endif
    6126             : 
    6127             : #if IK4_ENABLED
    6128             :     module function getReplacedCusComCusIns_D1_D0_D0_IK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6129             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6130             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_IK4
    6131             : #endif
    6132             :         use pm_kind, only: IKC => IK4
    6133             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    6134             :         integer(IKC)            , intent(in)                    :: pattern
    6135             :         integer(IKC)            , intent(in)                    :: replacement
    6136             :        !procedure(iseq_D0_D0_IK4)                               :: iseq
    6137             :         procedure(logical(LK))                                  :: iseq
    6138             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6139             :         logical(LK)             , intent(in)    , optional      :: sorted
    6140             :         logical(LK)             , intent(in)    , optional      :: unique
    6141             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    6142             :     end function
    6143             : #endif
    6144             : 
    6145             : #if IK3_ENABLED
    6146             :     module function getReplacedCusComCusIns_D1_D0_D0_IK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6147             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6148             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_IK3
    6149             : #endif
    6150             :         use pm_kind, only: IKC => IK3
    6151             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    6152             :         integer(IKC)            , intent(in)                    :: pattern
    6153             :         integer(IKC)            , intent(in)                    :: replacement
    6154             :        !procedure(iseq_D0_D0_IK3)                               :: iseq
    6155             :         procedure(logical(LK))                                  :: iseq
    6156             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6157             :         logical(LK)             , intent(in)    , optional      :: sorted
    6158             :         logical(LK)             , intent(in)    , optional      :: unique
    6159             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    6160             :     end function
    6161             : #endif
    6162             : 
    6163             : #if IK2_ENABLED
    6164             :     module function getReplacedCusComCusIns_D1_D0_D0_IK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6165             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6166             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_IK2
    6167             : #endif
    6168             :         use pm_kind, only: IKC => IK2
    6169             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    6170             :         integer(IKC)            , intent(in)                    :: pattern
    6171             :         integer(IKC)            , intent(in)                    :: replacement
    6172             :        !procedure(iseq_D0_D0_IK2)                               :: iseq
    6173             :         procedure(logical(LK))                                  :: iseq
    6174             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6175             :         logical(LK)             , intent(in)    , optional      :: sorted
    6176             :         logical(LK)             , intent(in)    , optional      :: unique
    6177             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    6178             :     end function
    6179             : 
    6180             : #endif
    6181             : 
    6182             : #if IK1_ENABLED
    6183             :     module function getReplacedCusComCusIns_D1_D0_D0_IK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6184             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6185             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_IK1
    6186             : #endif
    6187             :         use pm_kind, only: IKC => IK1
    6188             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    6189             :         integer(IKC)            , intent(in)                    :: pattern
    6190             :         integer(IKC)            , intent(in)                    :: replacement
    6191             :        !procedure(iseq_D0_D0_IK1)                               :: iseq
    6192             :         procedure(logical(LK))                                  :: iseq
    6193             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6194             :         logical(LK)             , intent(in)    , optional      :: sorted
    6195             :         logical(LK)             , intent(in)    , optional      :: unique
    6196             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    6197             :     end function
    6198             : #endif
    6199             : 
    6200             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6201             : 
    6202             : #if LK5_ENABLED
    6203             :     module function getReplacedCusComCusIns_D1_D0_D0_LK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6204             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6205             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_LK5
    6206             : #endif
    6207             :         use pm_kind, only: LKC => LK5
    6208             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    6209             :         logical(LKC)            , intent(in)                    :: pattern
    6210             :         logical(LKC)            , intent(in)                    :: replacement
    6211             :        !procedure(iseq_D0_D0_LK5)                               :: iseq
    6212             :         procedure(logical(LK))                                  :: iseq
    6213             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6214             :         logical(LK)             , intent(in)    , optional      :: sorted
    6215             :         logical(LK)             , intent(in)    , optional      :: unique
    6216             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    6217             :     end function
    6218             : #endif
    6219             : 
    6220             : #if LK4_ENABLED
    6221             :     module function getReplacedCusComCusIns_D1_D0_D0_LK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6222             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6223             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_LK4
    6224             : #endif
    6225             :         use pm_kind, only: LKC => LK4
    6226             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    6227             :         logical(LKC)            , intent(in)                    :: pattern
    6228             :         logical(LKC)            , intent(in)                    :: replacement
    6229             :        !procedure(iseq_D0_D0_LK4)                               :: iseq
    6230             :         procedure(logical(LK))                                  :: iseq
    6231             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6232             :         logical(LK)             , intent(in)    , optional      :: sorted
    6233             :         logical(LK)             , intent(in)    , optional      :: unique
    6234             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    6235             :     end function
    6236             : #endif
    6237             : 
    6238             : #if LK3_ENABLED
    6239             :     module function getReplacedCusComCusIns_D1_D0_D0_LK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6240             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6241             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_LK3
    6242             : #endif
    6243             :         use pm_kind, only: LKC => LK3
    6244             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    6245             :         logical(LKC)            , intent(in)                    :: pattern
    6246             :         logical(LKC)            , intent(in)                    :: replacement
    6247             :        !procedure(iseq_D0_D0_LK3)                               :: iseq
    6248             :         procedure(logical(LK))                                  :: iseq
    6249             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6250             :         logical(LK)             , intent(in)    , optional      :: sorted
    6251             :         logical(LK)             , intent(in)    , optional      :: unique
    6252             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    6253             :     end function
    6254             : #endif
    6255             : 
    6256             : #if LK2_ENABLED
    6257             :     module function getReplacedCusComCusIns_D1_D0_D0_LK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6258             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6259             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_LK2
    6260             : #endif
    6261             :         use pm_kind, only: LKC => LK2
    6262             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    6263             :         logical(LKC)            , intent(in)                    :: pattern
    6264             :         logical(LKC)            , intent(in)                    :: replacement
    6265             :        !procedure(iseq_D0_D0_LK2)                               :: iseq
    6266             :         procedure(logical(LK))                                  :: iseq
    6267             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6268             :         logical(LK)             , intent(in)    , optional      :: sorted
    6269             :         logical(LK)             , intent(in)    , optional      :: unique
    6270             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    6271             :     end function
    6272             : 
    6273             : #endif
    6274             : 
    6275             : #if LK1_ENABLED
    6276             :     module function getReplacedCusComCusIns_D1_D0_D0_LK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6277             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6278             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_LK1
    6279             : #endif
    6280             :         use pm_kind, only: LKC => LK1
    6281             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    6282             :         logical(LKC)            , intent(in)                    :: pattern
    6283             :         logical(LKC)            , intent(in)                    :: replacement
    6284             :        !procedure(iseq_D0_D0_LK1)                               :: iseq
    6285             :         procedure(logical(LK))                                  :: iseq
    6286             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6287             :         logical(LK)             , intent(in)    , optional      :: sorted
    6288             :         logical(LK)             , intent(in)    , optional      :: unique
    6289             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    6290             :     end function
    6291             : #endif
    6292             : 
    6293             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6294             : 
    6295             : #if CK5_ENABLED
    6296             :     module function getReplacedCusComCusIns_D1_D0_D0_CK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6297             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6298             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_CK5
    6299             : #endif
    6300             :         use pm_kind, only: CKC => CK5
    6301             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    6302             :         complex(CKC)            , intent(in)                    :: pattern
    6303             :         complex(CKC)            , intent(in)                    :: replacement
    6304             :        !procedure(iseq_D0_D0_CK5)                               :: iseq
    6305             :         procedure(logical(LK))                                  :: iseq
    6306             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6307             :         logical(LK)             , intent(in)    , optional      :: sorted
    6308             :         logical(LK)             , intent(in)    , optional      :: unique
    6309             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    6310             :     end function
    6311             : #endif
    6312             : 
    6313             : #if CK4_ENABLED
    6314             :     module function getReplacedCusComCusIns_D1_D0_D0_CK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6315             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6316             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_CK4
    6317             : #endif
    6318             :         use pm_kind, only: CKC => CK4
    6319             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    6320             :         complex(CKC)            , intent(in)                    :: pattern
    6321             :         complex(CKC)            , intent(in)                    :: replacement
    6322             :        !procedure(iseq_D0_D0_CK4)                               :: iseq
    6323             :         procedure(logical(LK))                                  :: iseq
    6324             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6325             :         logical(LK)             , intent(in)    , optional      :: sorted
    6326             :         logical(LK)             , intent(in)    , optional      :: unique
    6327             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    6328             :     end function
    6329             : #endif
    6330             : 
    6331             : #if CK3_ENABLED
    6332             :     module function getReplacedCusComCusIns_D1_D0_D0_CK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6333             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6334             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_CK3
    6335             : #endif
    6336             :         use pm_kind, only: CKC => CK3
    6337             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    6338             :         complex(CKC)            , intent(in)                    :: pattern
    6339             :         complex(CKC)            , intent(in)                    :: replacement
    6340             :        !procedure(iseq_D0_D0_CK3)                               :: iseq
    6341             :         procedure(logical(LK))                                  :: iseq
    6342             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6343             :         logical(LK)             , intent(in)    , optional      :: sorted
    6344             :         logical(LK)             , intent(in)    , optional      :: unique
    6345             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    6346             :     end function
    6347             : #endif
    6348             : 
    6349             : #if CK2_ENABLED
    6350             :     module function getReplacedCusComCusIns_D1_D0_D0_CK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6351             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6352             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_CK2
    6353             : #endif
    6354             :         use pm_kind, only: CKC => CK2
    6355             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    6356             :         complex(CKC)            , intent(in)                    :: pattern
    6357             :         complex(CKC)            , intent(in)                    :: replacement
    6358             :        !procedure(iseq_D0_D0_CK2)                               :: iseq
    6359             :         procedure(logical(LK))                                  :: iseq
    6360             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6361             :         logical(LK)             , intent(in)    , optional      :: sorted
    6362             :         logical(LK)             , intent(in)    , optional      :: unique
    6363             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    6364             :     end function
    6365             : 
    6366             : #endif
    6367             : 
    6368             : #if CK1_ENABLED
    6369             :     module function getReplacedCusComCusIns_D1_D0_D0_CK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6370             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6371             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_CK1
    6372             : #endif
    6373             :         use pm_kind, only: CKC => CK1
    6374             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    6375             :         complex(CKC)            , intent(in)                    :: pattern
    6376             :         complex(CKC)            , intent(in)                    :: replacement
    6377             :        !procedure(iseq_D0_D0_CK1)                               :: iseq
    6378             :         procedure(logical(LK))                                  :: iseq
    6379             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6380             :         logical(LK)             , intent(in)    , optional      :: sorted
    6381             :         logical(LK)             , intent(in)    , optional      :: unique
    6382             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    6383             :     end function
    6384             : #endif
    6385             : 
    6386             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6387             : 
    6388             : #if RK5_ENABLED
    6389             :     module function getReplacedCusComCusIns_D1_D0_D0_RK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6390             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6391             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_RK5
    6392             : #endif
    6393             :         use pm_kind, only: RKC => RK5
    6394             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    6395             :         real(RKC)               , intent(in)                    :: pattern
    6396             :         real(RKC)               , intent(in)                    :: replacement
    6397             :        !procedure(iseq_D0_D0_RK5)                               :: iseq
    6398             :         procedure(logical(LK))                                  :: iseq
    6399             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6400             :         logical(LK)             , intent(in)    , optional      :: sorted
    6401             :         logical(LK)             , intent(in)    , optional      :: unique
    6402             :         real(RKC)                               , allocatable   :: arrayNew(:)
    6403             :     end function
    6404             : #endif
    6405             : 
    6406             : #if RK4_ENABLED
    6407             :     module function getReplacedCusComCusIns_D1_D0_D0_RK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6408             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6409             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_RK4
    6410             : #endif
    6411             :         use pm_kind, only: RKC => RK4
    6412             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    6413             :         real(RKC)               , intent(in)                    :: pattern
    6414             :         real(RKC)               , intent(in)                    :: replacement
    6415             :        !procedure(iseq_D0_D0_RK4)                               :: iseq
    6416             :         procedure(logical(LK))                                  :: iseq
    6417             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6418             :         logical(LK)             , intent(in)    , optional      :: sorted
    6419             :         logical(LK)             , intent(in)    , optional      :: unique
    6420             :         real(RKC)                               , allocatable   :: arrayNew(:)
    6421             :     end function
    6422             : #endif
    6423             : 
    6424             : #if RK3_ENABLED
    6425             :     module function getReplacedCusComCusIns_D1_D0_D0_RK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6426             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6427             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_RK3
    6428             : #endif
    6429             :         use pm_kind, only: RKC => RK3
    6430             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    6431             :         real(RKC)               , intent(in)                    :: pattern
    6432             :         real(RKC)               , intent(in)                    :: replacement
    6433             :        !procedure(iseq_D0_D0_RK3)                               :: iseq
    6434             :         procedure(logical(LK))                                  :: iseq
    6435             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6436             :         logical(LK)             , intent(in)    , optional      :: sorted
    6437             :         logical(LK)             , intent(in)    , optional      :: unique
    6438             :         real(RKC)                               , allocatable   :: arrayNew(:)
    6439             :     end function
    6440             : #endif
    6441             : 
    6442             : #if RK2_ENABLED
    6443             :     module function getReplacedCusComCusIns_D1_D0_D0_RK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6444             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6445             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_RK2
    6446             : #endif
    6447             :         use pm_kind, only: RKC => RK2
    6448             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    6449             :         real(RKC)               , intent(in)                    :: pattern
    6450             :         real(RKC)               , intent(in)                    :: replacement
    6451             :        !procedure(iseq_D0_D0_RK2)                               :: iseq
    6452             :         procedure(logical(LK))                                  :: iseq
    6453             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6454             :         logical(LK)             , intent(in)    , optional      :: sorted
    6455             :         logical(LK)             , intent(in)    , optional      :: unique
    6456             :         real(RKC)                               , allocatable   :: arrayNew(:)
    6457             :     end function
    6458             : 
    6459             : #endif
    6460             : 
    6461             : #if RK1_ENABLED
    6462             :     module function getReplacedCusComCusIns_D1_D0_D0_RK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6463             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6464             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D0_RK1
    6465             : #endif
    6466             :         use pm_kind, only: RKC => RK1
    6467             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    6468             :         real(RKC)               , intent(in)                    :: pattern
    6469             :         real(RKC)               , intent(in)                    :: replacement
    6470             :        !procedure(iseq_D0_D0_RK1)                               :: iseq
    6471             :         procedure(logical(LK))                                  :: iseq
    6472             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6473             :         logical(LK)             , intent(in)    , optional      :: sorted
    6474             :         logical(LK)             , intent(in)    , optional      :: unique
    6475             :         real(RKC)                               , allocatable   :: arrayNew(:)
    6476             :     end function
    6477             : #endif
    6478             : 
    6479             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6480             : 
    6481             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6482             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6483             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6484             : 
    6485             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6486             : 
    6487             : #if SK5_ENABLED
    6488             :     module function getReplacedCusComCusIns_D1_D0_D1_SK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6489             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6490             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_SK5
    6491             : #endif
    6492             :         use pm_kind, only: SKC => SK5
    6493             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6494             :         character(*,SKC)        , intent(in)                    :: pattern
    6495             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    6496             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
    6497             :         procedure(logical(LK))                                  :: iseq
    6498             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6499             :         logical(LK)             , intent(in)    , optional      :: sorted
    6500             :         logical(LK)             , intent(in)    , optional      :: unique
    6501             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6502             :     end function
    6503             : #endif
    6504             : 
    6505             : #if SK4_ENABLED
    6506             :     module function getReplacedCusComCusIns_D1_D0_D1_SK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6507             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6508             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_SK4
    6509             : #endif
    6510             :         use pm_kind, only: SKC => SK4
    6511             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6512             :         character(*,SKC)        , intent(in)                    :: pattern
    6513             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    6514             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
    6515             :         procedure(logical(LK))                                  :: iseq
    6516             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6517             :         logical(LK)             , intent(in)    , optional      :: sorted
    6518             :         logical(LK)             , intent(in)    , optional      :: unique
    6519             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6520             :     end function
    6521             : #endif
    6522             : 
    6523             : #if SK3_ENABLED
    6524             :     module function getReplacedCusComCusIns_D1_D0_D1_SK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6525             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6526             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_SK3
    6527             : #endif
    6528             :         use pm_kind, only: SKC => SK3
    6529             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6530             :         character(*,SKC)        , intent(in)                    :: pattern
    6531             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    6532             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
    6533             :         procedure(logical(LK))                                  :: iseq
    6534             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6535             :         logical(LK)             , intent(in)    , optional      :: sorted
    6536             :         logical(LK)             , intent(in)    , optional      :: unique
    6537             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6538             :     end function
    6539             : #endif
    6540             : 
    6541             : #if SK2_ENABLED
    6542             :     module function getReplacedCusComCusIns_D1_D0_D1_SK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6543             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6544             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_SK2
    6545             : #endif
    6546             :         use pm_kind, only: SKC => SK2
    6547             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6548             :         character(*,SKC)        , intent(in)                    :: pattern
    6549             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    6550             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
    6551             :         procedure(logical(LK))                                  :: iseq
    6552             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6553             :         logical(LK)             , intent(in)    , optional      :: sorted
    6554             :         logical(LK)             , intent(in)    , optional      :: unique
    6555             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6556             :     end function
    6557             : 
    6558             : #endif
    6559             : 
    6560             : #if SK1_ENABLED
    6561             :     module function getReplacedCusComCusIns_D1_D0_D1_SK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6562             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6563             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_SK1
    6564             : #endif
    6565             :         use pm_kind, only: SKC => SK1
    6566             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6567             :         character(*,SKC)        , intent(in)                    :: pattern
    6568             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    6569             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
    6570             :         procedure(logical(LK))                                  :: iseq
    6571             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6572             :         logical(LK)             , intent(in)    , optional      :: sorted
    6573             :         logical(LK)             , intent(in)    , optional      :: unique
    6574             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6575             :     end function
    6576             : #endif
    6577             : 
    6578             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6579             : 
    6580             : #if IK5_ENABLED
    6581             :     module function getReplacedCusComCusIns_D1_D0_D1_IK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6582             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6583             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_IK5
    6584             : #endif
    6585             :         use pm_kind, only: IKC => IK5
    6586             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    6587             :         integer(IKC)            , intent(in)                    :: pattern
    6588             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    6589             :        !procedure(iseq_D0_D0_IK5)                               :: iseq
    6590             :         procedure(logical(LK))                                  :: iseq
    6591             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6592             :         logical(LK)             , intent(in)    , optional      :: sorted
    6593             :         logical(LK)             , intent(in)    , optional      :: unique
    6594             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    6595             :     end function
    6596             : #endif
    6597             : 
    6598             : #if IK4_ENABLED
    6599             :     module function getReplacedCusComCusIns_D1_D0_D1_IK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6600             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6601             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_IK4
    6602             : #endif
    6603             :         use pm_kind, only: IKC => IK4
    6604             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    6605             :         integer(IKC)            , intent(in)                    :: pattern
    6606             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    6607             :        !procedure(iseq_D0_D0_IK4)                               :: iseq
    6608             :         procedure(logical(LK))                                  :: iseq
    6609             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6610             :         logical(LK)             , intent(in)    , optional      :: sorted
    6611             :         logical(LK)             , intent(in)    , optional      :: unique
    6612             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    6613             :     end function
    6614             : #endif
    6615             : 
    6616             : #if IK3_ENABLED
    6617             :     module function getReplacedCusComCusIns_D1_D0_D1_IK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6618             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6619             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_IK3
    6620             : #endif
    6621             :         use pm_kind, only: IKC => IK3
    6622             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    6623             :         integer(IKC)            , intent(in)                    :: pattern
    6624             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    6625             :        !procedure(iseq_D0_D0_IK3)                               :: iseq
    6626             :         procedure(logical(LK))                                  :: iseq
    6627             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6628             :         logical(LK)             , intent(in)    , optional      :: sorted
    6629             :         logical(LK)             , intent(in)    , optional      :: unique
    6630             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    6631             :     end function
    6632             : #endif
    6633             : 
    6634             : #if IK2_ENABLED
    6635             :     module function getReplacedCusComCusIns_D1_D0_D1_IK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6636             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6637             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_IK2
    6638             : #endif
    6639             :         use pm_kind, only: IKC => IK2
    6640             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    6641             :         integer(IKC)            , intent(in)                    :: pattern
    6642             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    6643             :        !procedure(iseq_D0_D0_IK2)                               :: iseq
    6644             :         procedure(logical(LK))                                  :: iseq
    6645             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6646             :         logical(LK)             , intent(in)    , optional      :: sorted
    6647             :         logical(LK)             , intent(in)    , optional      :: unique
    6648             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    6649             :     end function
    6650             : 
    6651             : #endif
    6652             : 
    6653             : #if IK1_ENABLED
    6654             :     module function getReplacedCusComCusIns_D1_D0_D1_IK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6655             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6656             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_IK1
    6657             : #endif
    6658             :         use pm_kind, only: IKC => IK1
    6659             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    6660             :         integer(IKC)            , intent(in)                    :: pattern
    6661             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    6662             :        !procedure(iseq_D0_D0_IK1)                               :: iseq
    6663             :         procedure(logical(LK))                                  :: iseq
    6664             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6665             :         logical(LK)             , intent(in)    , optional      :: sorted
    6666             :         logical(LK)             , intent(in)    , optional      :: unique
    6667             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    6668             :     end function
    6669             : #endif
    6670             : 
    6671             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6672             : 
    6673             : #if LK5_ENABLED
    6674             :     module function getReplacedCusComCusIns_D1_D0_D1_LK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6675             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6676             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_LK5
    6677             : #endif
    6678             :         use pm_kind, only: LKC => LK5
    6679             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    6680             :         logical(LKC)            , intent(in)                    :: pattern
    6681             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    6682             :        !procedure(iseq_D0_D0_LK5)                               :: iseq
    6683             :         procedure(logical(LK))                                  :: iseq
    6684             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6685             :         logical(LK)             , intent(in)    , optional      :: sorted
    6686             :         logical(LK)             , intent(in)    , optional      :: unique
    6687             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    6688             :     end function
    6689             : #endif
    6690             : 
    6691             : #if LK4_ENABLED
    6692             :     module function getReplacedCusComCusIns_D1_D0_D1_LK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6693             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6694             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_LK4
    6695             : #endif
    6696             :         use pm_kind, only: LKC => LK4
    6697             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    6698             :         logical(LKC)            , intent(in)                    :: pattern
    6699             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    6700             :        !procedure(iseq_D0_D0_LK4)                               :: iseq
    6701             :         procedure(logical(LK))                                  :: iseq
    6702             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6703             :         logical(LK)             , intent(in)    , optional      :: sorted
    6704             :         logical(LK)             , intent(in)    , optional      :: unique
    6705             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    6706             :     end function
    6707             : #endif
    6708             : 
    6709             : #if LK3_ENABLED
    6710             :     module function getReplacedCusComCusIns_D1_D0_D1_LK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6711             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6712             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_LK3
    6713             : #endif
    6714             :         use pm_kind, only: LKC => LK3
    6715             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    6716             :         logical(LKC)            , intent(in)                    :: pattern
    6717             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    6718             :        !procedure(iseq_D0_D0_LK3)                               :: iseq
    6719             :         procedure(logical(LK))                                  :: iseq
    6720             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6721             :         logical(LK)             , intent(in)    , optional      :: sorted
    6722             :         logical(LK)             , intent(in)    , optional      :: unique
    6723             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    6724             :     end function
    6725             : #endif
    6726             : 
    6727             : #if LK2_ENABLED
    6728             :     module function getReplacedCusComCusIns_D1_D0_D1_LK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6729             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6730             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_LK2
    6731             : #endif
    6732             :         use pm_kind, only: LKC => LK2
    6733             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    6734             :         logical(LKC)            , intent(in)                    :: pattern
    6735             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    6736             :        !procedure(iseq_D0_D0_LK2)                               :: iseq
    6737             :         procedure(logical(LK))                                  :: iseq
    6738             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6739             :         logical(LK)             , intent(in)    , optional      :: sorted
    6740             :         logical(LK)             , intent(in)    , optional      :: unique
    6741             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    6742             :     end function
    6743             : 
    6744             : #endif
    6745             : 
    6746             : #if LK1_ENABLED
    6747             :     module function getReplacedCusComCusIns_D1_D0_D1_LK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6748             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6749             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_LK1
    6750             : #endif
    6751             :         use pm_kind, only: LKC => LK1
    6752             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    6753             :         logical(LKC)            , intent(in)                    :: pattern
    6754             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    6755             :        !procedure(iseq_D0_D0_LK1)                               :: iseq
    6756             :         procedure(logical(LK))                                  :: iseq
    6757             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6758             :         logical(LK)             , intent(in)    , optional      :: sorted
    6759             :         logical(LK)             , intent(in)    , optional      :: unique
    6760             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    6761             :     end function
    6762             : #endif
    6763             : 
    6764             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6765             : 
    6766             : #if CK5_ENABLED
    6767             :     module function getReplacedCusComCusIns_D1_D0_D1_CK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6768             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6769             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_CK5
    6770             : #endif
    6771             :         use pm_kind, only: CKC => CK5
    6772             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    6773             :         complex(CKC)            , intent(in)                    :: pattern
    6774             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    6775             :        !procedure(iseq_D0_D0_CK5)                               :: iseq
    6776             :         procedure(logical(LK))                                  :: iseq
    6777             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6778             :         logical(LK)             , intent(in)    , optional      :: sorted
    6779             :         logical(LK)             , intent(in)    , optional      :: unique
    6780             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    6781             :     end function
    6782             : #endif
    6783             : 
    6784             : #if CK4_ENABLED
    6785             :     module function getReplacedCusComCusIns_D1_D0_D1_CK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6786             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6787             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_CK4
    6788             : #endif
    6789             :         use pm_kind, only: CKC => CK4
    6790             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    6791             :         complex(CKC)            , intent(in)                    :: pattern
    6792             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    6793             :        !procedure(iseq_D0_D0_CK4)                               :: iseq
    6794             :         procedure(logical(LK))                                  :: iseq
    6795             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6796             :         logical(LK)             , intent(in)    , optional      :: sorted
    6797             :         logical(LK)             , intent(in)    , optional      :: unique
    6798             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    6799             :     end function
    6800             : #endif
    6801             : 
    6802             : #if CK3_ENABLED
    6803             :     module function getReplacedCusComCusIns_D1_D0_D1_CK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6804             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6805             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_CK3
    6806             : #endif
    6807             :         use pm_kind, only: CKC => CK3
    6808             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    6809             :         complex(CKC)            , intent(in)                    :: pattern
    6810             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    6811             :        !procedure(iseq_D0_D0_CK3)                               :: iseq
    6812             :         procedure(logical(LK))                                  :: iseq
    6813             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6814             :         logical(LK)             , intent(in)    , optional      :: sorted
    6815             :         logical(LK)             , intent(in)    , optional      :: unique
    6816             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    6817             :     end function
    6818             : #endif
    6819             : 
    6820             : #if CK2_ENABLED
    6821             :     module function getReplacedCusComCusIns_D1_D0_D1_CK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6822             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6823             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_CK2
    6824             : #endif
    6825             :         use pm_kind, only: CKC => CK2
    6826             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    6827             :         complex(CKC)            , intent(in)                    :: pattern
    6828             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    6829             :        !procedure(iseq_D0_D0_CK2)                               :: iseq
    6830             :         procedure(logical(LK))                                  :: iseq
    6831             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6832             :         logical(LK)             , intent(in)    , optional      :: sorted
    6833             :         logical(LK)             , intent(in)    , optional      :: unique
    6834             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    6835             :     end function
    6836             : 
    6837             : #endif
    6838             : 
    6839             : #if CK1_ENABLED
    6840             :     module function getReplacedCusComCusIns_D1_D0_D1_CK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6841             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6842             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_CK1
    6843             : #endif
    6844             :         use pm_kind, only: CKC => CK1
    6845             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    6846             :         complex(CKC)            , intent(in)                    :: pattern
    6847             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    6848             :        !procedure(iseq_D0_D0_CK1)                               :: iseq
    6849             :         procedure(logical(LK))                                  :: iseq
    6850             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6851             :         logical(LK)             , intent(in)    , optional      :: sorted
    6852             :         logical(LK)             , intent(in)    , optional      :: unique
    6853             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    6854             :     end function
    6855             : #endif
    6856             : 
    6857             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6858             : 
    6859             : #if RK5_ENABLED
    6860             :     module function getReplacedCusComCusIns_D1_D0_D1_RK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6861             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6862             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_RK5
    6863             : #endif
    6864             :         use pm_kind, only: RKC => RK5
    6865             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    6866             :         real(RKC)               , intent(in)                    :: pattern
    6867             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    6868             :        !procedure(iseq_D0_D0_RK5)                               :: iseq
    6869             :         procedure(logical(LK))                                  :: iseq
    6870             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6871             :         logical(LK)             , intent(in)    , optional      :: sorted
    6872             :         logical(LK)             , intent(in)    , optional      :: unique
    6873             :         real(RKC)                               , allocatable   :: arrayNew(:)
    6874             :     end function
    6875             : #endif
    6876             : 
    6877             : #if RK4_ENABLED
    6878             :     module function getReplacedCusComCusIns_D1_D0_D1_RK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6879             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6880             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_RK4
    6881             : #endif
    6882             :         use pm_kind, only: RKC => RK4
    6883             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    6884             :         real(RKC)               , intent(in)                    :: pattern
    6885             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    6886             :        !procedure(iseq_D0_D0_RK4)                               :: iseq
    6887             :         procedure(logical(LK))                                  :: iseq
    6888             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6889             :         logical(LK)             , intent(in)    , optional      :: sorted
    6890             :         logical(LK)             , intent(in)    , optional      :: unique
    6891             :         real(RKC)                               , allocatable   :: arrayNew(:)
    6892             :     end function
    6893             : #endif
    6894             : 
    6895             : #if RK3_ENABLED
    6896             :     module function getReplacedCusComCusIns_D1_D0_D1_RK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6897             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6898             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_RK3
    6899             : #endif
    6900             :         use pm_kind, only: RKC => RK3
    6901             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    6902             :         real(RKC)               , intent(in)                    :: pattern
    6903             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    6904             :        !procedure(iseq_D0_D0_RK3)                               :: iseq
    6905             :         procedure(logical(LK))                                  :: iseq
    6906             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6907             :         logical(LK)             , intent(in)    , optional      :: sorted
    6908             :         logical(LK)             , intent(in)    , optional      :: unique
    6909             :         real(RKC)                               , allocatable   :: arrayNew(:)
    6910             :     end function
    6911             : #endif
    6912             : 
    6913             : #if RK2_ENABLED
    6914             :     module function getReplacedCusComCusIns_D1_D0_D1_RK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6915             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6916             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_RK2
    6917             : #endif
    6918             :         use pm_kind, only: RKC => RK2
    6919             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    6920             :         real(RKC)               , intent(in)                    :: pattern
    6921             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    6922             :        !procedure(iseq_D0_D0_RK2)                               :: iseq
    6923             :         procedure(logical(LK))                                  :: iseq
    6924             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6925             :         logical(LK)             , intent(in)    , optional      :: sorted
    6926             :         logical(LK)             , intent(in)    , optional      :: unique
    6927             :         real(RKC)                               , allocatable   :: arrayNew(:)
    6928             :     end function
    6929             : 
    6930             : #endif
    6931             : 
    6932             : #if RK1_ENABLED
    6933             :     module function getReplacedCusComCusIns_D1_D0_D1_RK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6934             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6935             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D0_D1_RK1
    6936             : #endif
    6937             :         use pm_kind, only: RKC => RK1
    6938             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    6939             :         real(RKC)               , intent(in)                    :: pattern
    6940             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    6941             :        !procedure(iseq_D0_D0_RK1)                               :: iseq
    6942             :         procedure(logical(LK))                                  :: iseq
    6943             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6944             :         logical(LK)             , intent(in)    , optional      :: sorted
    6945             :         logical(LK)             , intent(in)    , optional      :: unique
    6946             :         real(RKC)                               , allocatable   :: arrayNew(:)
    6947             :     end function
    6948             : #endif
    6949             : 
    6950             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6951             : 
    6952             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6953             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6954             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6955             : 
    6956             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    6957             : 
    6958             : #if SK5_ENABLED
    6959             :     module function getReplacedCusComCusIns_D1_D1_D0_SK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6960             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6961             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_SK5
    6962             : #endif
    6963             :         use pm_kind, only: SKC => SK5
    6964             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6965             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    6966             :         character(*,SKC)        , intent(in)                    :: replacement
    6967             :        !procedure(iseq_D1_D1_SK5)                               :: iseq
    6968             :         procedure(logical(LK))                                  :: iseq
    6969             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6970             :         logical(LK)             , intent(in)    , optional      :: sorted
    6971             :         logical(LK)             , intent(in)    , optional      :: unique
    6972             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6973             :     end function
    6974             : #endif
    6975             : 
    6976             : #if SK4_ENABLED
    6977             :     module function getReplacedCusComCusIns_D1_D1_D0_SK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6978             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6979             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_SK4
    6980             : #endif
    6981             :         use pm_kind, only: SKC => SK4
    6982             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    6983             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    6984             :         character(*,SKC)        , intent(in)                    :: replacement
    6985             :        !procedure(iseq_D1_D1_SK4)                               :: iseq
    6986             :         procedure(logical(LK))                                  :: iseq
    6987             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    6988             :         logical(LK)             , intent(in)    , optional      :: sorted
    6989             :         logical(LK)             , intent(in)    , optional      :: unique
    6990             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    6991             :     end function
    6992             : #endif
    6993             : 
    6994             : #if SK3_ENABLED
    6995             :     module function getReplacedCusComCusIns_D1_D1_D0_SK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    6996             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    6997             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_SK3
    6998             : #endif
    6999             :         use pm_kind, only: SKC => SK3
    7000             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    7001             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    7002             :         character(*,SKC)        , intent(in)                    :: replacement
    7003             :        !procedure(iseq_D1_D1_SK3)                               :: iseq
    7004             :         procedure(logical(LK))                                  :: iseq
    7005             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7006             :         logical(LK)             , intent(in)    , optional      :: sorted
    7007             :         logical(LK)             , intent(in)    , optional      :: unique
    7008             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    7009             :     end function
    7010             : #endif
    7011             : 
    7012             : #if SK2_ENABLED
    7013             :     module function getReplacedCusComCusIns_D1_D1_D0_SK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7014             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7015             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_SK2
    7016             : #endif
    7017             :         use pm_kind, only: SKC => SK2
    7018             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    7019             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    7020             :         character(*,SKC)        , intent(in)                    :: replacement
    7021             :        !procedure(iseq_D1_D1_SK2)                               :: iseq
    7022             :         procedure(logical(LK))                                  :: iseq
    7023             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7024             :         logical(LK)             , intent(in)    , optional      :: sorted
    7025             :         logical(LK)             , intent(in)    , optional      :: unique
    7026             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    7027             :     end function
    7028             : 
    7029             : #endif
    7030             : 
    7031             : #if SK1_ENABLED
    7032             :     module function getReplacedCusComCusIns_D1_D1_D0_SK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7033             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7034             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_SK1
    7035             : #endif
    7036             :         use pm_kind, only: SKC => SK1
    7037             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    7038             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    7039             :         character(*,SKC)        , intent(in)                    :: replacement
    7040             :        !procedure(iseq_D1_D1_SK1)                               :: iseq
    7041             :         procedure(logical(LK))                                  :: iseq
    7042             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7043             :         logical(LK)             , intent(in)    , optional      :: sorted
    7044             :         logical(LK)             , intent(in)    , optional      :: unique
    7045             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    7046             :     end function
    7047             : #endif
    7048             : 
    7049             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7050             : 
    7051             : #if IK5_ENABLED
    7052             :     module function getReplacedCusComCusIns_D1_D1_D0_IK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7053             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7054             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_IK5
    7055             : #endif
    7056             :         use pm_kind, only: IKC => IK5
    7057             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    7058             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    7059             :         integer(IKC)            , intent(in)                    :: replacement
    7060             :        !procedure(iseq_D1_D1_IK5)                               :: iseq
    7061             :         procedure(logical(LK))                                  :: iseq
    7062             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7063             :         logical(LK)             , intent(in)    , optional      :: sorted
    7064             :         logical(LK)             , intent(in)    , optional      :: unique
    7065             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    7066             :     end function
    7067             : #endif
    7068             : 
    7069             : #if IK4_ENABLED
    7070             :     module function getReplacedCusComCusIns_D1_D1_D0_IK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7071             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7072             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_IK4
    7073             : #endif
    7074             :         use pm_kind, only: IKC => IK4
    7075             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    7076             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    7077             :         integer(IKC)            , intent(in)                    :: replacement
    7078             :        !procedure(iseq_D1_D1_IK4)                               :: iseq
    7079             :         procedure(logical(LK))                                  :: iseq
    7080             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7081             :         logical(LK)             , intent(in)    , optional      :: sorted
    7082             :         logical(LK)             , intent(in)    , optional      :: unique
    7083             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    7084             :     end function
    7085             : #endif
    7086             : 
    7087             : #if IK3_ENABLED
    7088             :     module function getReplacedCusComCusIns_D1_D1_D0_IK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7089             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7090             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_IK3
    7091             : #endif
    7092             :         use pm_kind, only: IKC => IK3
    7093             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    7094             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    7095             :         integer(IKC)            , intent(in)                    :: replacement
    7096             :        !procedure(iseq_D1_D1_IK3)                               :: iseq
    7097             :         procedure(logical(LK))                                  :: iseq
    7098             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7099             :         logical(LK)             , intent(in)    , optional      :: sorted
    7100             :         logical(LK)             , intent(in)    , optional      :: unique
    7101             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    7102             :     end function
    7103             : #endif
    7104             : 
    7105             : #if IK2_ENABLED
    7106             :     module function getReplacedCusComCusIns_D1_D1_D0_IK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7107             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7108             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_IK2
    7109             : #endif
    7110             :         use pm_kind, only: IKC => IK2
    7111             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    7112             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    7113             :         integer(IKC)            , intent(in)                    :: replacement
    7114             :        !procedure(iseq_D1_D1_IK2)                               :: iseq
    7115             :         procedure(logical(LK))                                  :: iseq
    7116             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7117             :         logical(LK)             , intent(in)    , optional      :: sorted
    7118             :         logical(LK)             , intent(in)    , optional      :: unique
    7119             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    7120             :     end function
    7121             : 
    7122             : #endif
    7123             : 
    7124             : #if IK1_ENABLED
    7125             :     module function getReplacedCusComCusIns_D1_D1_D0_IK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7126             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7127             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_IK1
    7128             : #endif
    7129             :         use pm_kind, only: IKC => IK1
    7130             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    7131             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    7132             :         integer(IKC)            , intent(in)                    :: replacement
    7133             :        !procedure(iseq_D1_D1_IK1)                               :: iseq
    7134             :         procedure(logical(LK))                                  :: iseq
    7135             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7136             :         logical(LK)             , intent(in)    , optional      :: sorted
    7137             :         logical(LK)             , intent(in)    , optional      :: unique
    7138             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    7139             :     end function
    7140             : #endif
    7141             : 
    7142             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7143             : 
    7144             : #if LK5_ENABLED
    7145             :     module function getReplacedCusComCusIns_D1_D1_D0_LK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7146             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7147             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_LK5
    7148             : #endif
    7149             :         use pm_kind, only: LKC => LK5
    7150             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    7151             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    7152             :         logical(LKC)            , intent(in)                    :: replacement
    7153             :        !procedure(iseq_D1_D1_LK5)                               :: iseq
    7154             :         procedure(logical(LK))                                  :: iseq
    7155             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7156             :         logical(LK)             , intent(in)    , optional      :: sorted
    7157             :         logical(LK)             , intent(in)    , optional      :: unique
    7158             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    7159             :     end function
    7160             : #endif
    7161             : 
    7162             : #if LK4_ENABLED
    7163             :     module function getReplacedCusComCusIns_D1_D1_D0_LK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7164             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7165             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_LK4
    7166             : #endif
    7167             :         use pm_kind, only: LKC => LK4
    7168             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    7169             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    7170             :         logical(LKC)            , intent(in)                    :: replacement
    7171             :        !procedure(iseq_D1_D1_LK4)                               :: iseq
    7172             :         procedure(logical(LK))                                  :: iseq
    7173             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7174             :         logical(LK)             , intent(in)    , optional      :: sorted
    7175             :         logical(LK)             , intent(in)    , optional      :: unique
    7176             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    7177             :     end function
    7178             : #endif
    7179             : 
    7180             : #if LK3_ENABLED
    7181             :     module function getReplacedCusComCusIns_D1_D1_D0_LK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7182             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7183             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_LK3
    7184             : #endif
    7185             :         use pm_kind, only: LKC => LK3
    7186             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    7187             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    7188             :         logical(LKC)            , intent(in)                    :: replacement
    7189             :        !procedure(iseq_D1_D1_LK3)                               :: iseq
    7190             :         procedure(logical(LK))                                  :: iseq
    7191             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7192             :         logical(LK)             , intent(in)    , optional      :: sorted
    7193             :         logical(LK)             , intent(in)    , optional      :: unique
    7194             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    7195             :     end function
    7196             : #endif
    7197             : 
    7198             : #if LK2_ENABLED
    7199             :     module function getReplacedCusComCusIns_D1_D1_D0_LK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7200             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7201             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_LK2
    7202             : #endif
    7203             :         use pm_kind, only: LKC => LK2
    7204             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    7205             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    7206             :         logical(LKC)            , intent(in)                    :: replacement
    7207             :        !procedure(iseq_D1_D1_LK2)                               :: iseq
    7208             :         procedure(logical(LK))                                  :: iseq
    7209             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7210             :         logical(LK)             , intent(in)    , optional      :: sorted
    7211             :         logical(LK)             , intent(in)    , optional      :: unique
    7212             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    7213             :     end function
    7214             : 
    7215             : #endif
    7216             : 
    7217             : #if LK1_ENABLED
    7218             :     module function getReplacedCusComCusIns_D1_D1_D0_LK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7219             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7220             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_LK1
    7221             : #endif
    7222             :         use pm_kind, only: LKC => LK1
    7223             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    7224             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    7225             :         logical(LKC)            , intent(in)                    :: replacement
    7226             :        !procedure(iseq_D1_D1_LK1)                               :: iseq
    7227             :         procedure(logical(LK))                                  :: iseq
    7228             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7229             :         logical(LK)             , intent(in)    , optional      :: sorted
    7230             :         logical(LK)             , intent(in)    , optional      :: unique
    7231             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    7232             :     end function
    7233             : #endif
    7234             : 
    7235             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7236             : 
    7237             : #if CK5_ENABLED
    7238             :     module function getReplacedCusComCusIns_D1_D1_D0_CK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7239             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7240             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_CK5
    7241             : #endif
    7242             :         use pm_kind, only: CKC => CK5
    7243             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    7244             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    7245             :         complex(CKC)            , intent(in)                    :: replacement
    7246             :        !procedure(iseq_D1_D1_CK5)                               :: iseq
    7247             :         procedure(logical(LK))                                  :: iseq
    7248             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7249             :         logical(LK)             , intent(in)    , optional      :: sorted
    7250             :         logical(LK)             , intent(in)    , optional      :: unique
    7251             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    7252             :     end function
    7253             : #endif
    7254             : 
    7255             : #if CK4_ENABLED
    7256             :     module function getReplacedCusComCusIns_D1_D1_D0_CK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7257             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7258             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_CK4
    7259             : #endif
    7260             :         use pm_kind, only: CKC => CK4
    7261             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    7262             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    7263             :         complex(CKC)            , intent(in)                    :: replacement
    7264             :        !procedure(iseq_D1_D1_CK4)                               :: iseq
    7265             :         procedure(logical(LK))                                  :: iseq
    7266             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7267             :         logical(LK)             , intent(in)    , optional      :: sorted
    7268             :         logical(LK)             , intent(in)    , optional      :: unique
    7269             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    7270             :     end function
    7271             : #endif
    7272             : 
    7273             : #if CK3_ENABLED
    7274             :     module function getReplacedCusComCusIns_D1_D1_D0_CK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7275             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7276             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_CK3
    7277             : #endif
    7278             :         use pm_kind, only: CKC => CK3
    7279             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    7280             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    7281             :         complex(CKC)            , intent(in)                    :: replacement
    7282             :        !procedure(iseq_D1_D1_CK3)                               :: iseq
    7283             :         procedure(logical(LK))                                  :: iseq
    7284             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7285             :         logical(LK)             , intent(in)    , optional      :: sorted
    7286             :         logical(LK)             , intent(in)    , optional      :: unique
    7287             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    7288             :     end function
    7289             : #endif
    7290             : 
    7291             : #if CK2_ENABLED
    7292             :     module function getReplacedCusComCusIns_D1_D1_D0_CK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7293             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7294             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_CK2
    7295             : #endif
    7296             :         use pm_kind, only: CKC => CK2
    7297             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    7298             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    7299             :         complex(CKC)            , intent(in)                    :: replacement
    7300             :        !procedure(iseq_D1_D1_CK2)                               :: iseq
    7301             :         procedure(logical(LK))                                  :: iseq
    7302             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7303             :         logical(LK)             , intent(in)    , optional      :: sorted
    7304             :         logical(LK)             , intent(in)    , optional      :: unique
    7305             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    7306             :     end function
    7307             : 
    7308             : #endif
    7309             : 
    7310             : #if CK1_ENABLED
    7311             :     module function getReplacedCusComCusIns_D1_D1_D0_CK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7312             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7313             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_CK1
    7314             : #endif
    7315             :         use pm_kind, only: CKC => CK1
    7316             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    7317             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    7318             :         complex(CKC)            , intent(in)                    :: replacement
    7319             :        !procedure(iseq_D1_D1_CK1)                               :: iseq
    7320             :         procedure(logical(LK))                                  :: iseq
    7321             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7322             :         logical(LK)             , intent(in)    , optional      :: sorted
    7323             :         logical(LK)             , intent(in)    , optional      :: unique
    7324             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    7325             :     end function
    7326             : #endif
    7327             : 
    7328             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7329             : 
    7330             : #if RK5_ENABLED
    7331             :     module function getReplacedCusComCusIns_D1_D1_D0_RK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7332             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7333             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_RK5
    7334             : #endif
    7335             :         use pm_kind, only: RKC => RK5
    7336             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    7337             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    7338             :         real(RKC)               , intent(in)                    :: replacement
    7339             :        !procedure(iseq_D1_D1_RK5)                               :: iseq
    7340             :         procedure(logical(LK))                                  :: iseq
    7341             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7342             :         logical(LK)             , intent(in)    , optional      :: sorted
    7343             :         logical(LK)             , intent(in)    , optional      :: unique
    7344             :         real(RKC)                               , allocatable   :: arrayNew(:)
    7345             :     end function
    7346             : #endif
    7347             : 
    7348             : #if RK4_ENABLED
    7349             :     module function getReplacedCusComCusIns_D1_D1_D0_RK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7350             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7351             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_RK4
    7352             : #endif
    7353             :         use pm_kind, only: RKC => RK4
    7354             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    7355             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    7356             :         real(RKC)               , intent(in)                    :: replacement
    7357             :        !procedure(iseq_D1_D1_RK4)                               :: iseq
    7358             :         procedure(logical(LK))                                  :: iseq
    7359             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7360             :         logical(LK)             , intent(in)    , optional      :: sorted
    7361             :         logical(LK)             , intent(in)    , optional      :: unique
    7362             :         real(RKC)                               , allocatable   :: arrayNew(:)
    7363             :     end function
    7364             : #endif
    7365             : 
    7366             : #if RK3_ENABLED
    7367             :     module function getReplacedCusComCusIns_D1_D1_D0_RK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7368             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7369             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_RK3
    7370             : #endif
    7371             :         use pm_kind, only: RKC => RK3
    7372             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    7373             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    7374             :         real(RKC)               , intent(in)                    :: replacement
    7375             :        !procedure(iseq_D1_D1_RK3)                               :: iseq
    7376             :         procedure(logical(LK))                                  :: iseq
    7377             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7378             :         logical(LK)             , intent(in)    , optional      :: sorted
    7379             :         logical(LK)             , intent(in)    , optional      :: unique
    7380             :         real(RKC)                               , allocatable   :: arrayNew(:)
    7381             :     end function
    7382             : #endif
    7383             : 
    7384             : #if RK2_ENABLED
    7385             :     module function getReplacedCusComCusIns_D1_D1_D0_RK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7386             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7387             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_RK2
    7388             : #endif
    7389             :         use pm_kind, only: RKC => RK2
    7390             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    7391             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    7392             :         real(RKC)               , intent(in)                    :: replacement
    7393             :        !procedure(iseq_D1_D1_RK2)                               :: iseq
    7394             :         procedure(logical(LK))                                  :: iseq
    7395             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7396             :         logical(LK)             , intent(in)    , optional      :: sorted
    7397             :         logical(LK)             , intent(in)    , optional      :: unique
    7398             :         real(RKC)                               , allocatable   :: arrayNew(:)
    7399             :     end function
    7400             : 
    7401             : #endif
    7402             : 
    7403             : #if RK1_ENABLED
    7404             :     module function getReplacedCusComCusIns_D1_D1_D0_RK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7405             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7406             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D0_RK1
    7407             : #endif
    7408             :         use pm_kind, only: RKC => RK1
    7409             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    7410             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    7411             :         real(RKC)               , intent(in)                    :: replacement
    7412             :        !procedure(iseq_D1_D1_RK1)                               :: iseq
    7413             :         procedure(logical(LK))                                  :: iseq
    7414             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7415             :         logical(LK)             , intent(in)    , optional      :: sorted
    7416             :         logical(LK)             , intent(in)    , optional      :: unique
    7417             :         real(RKC)                               , allocatable   :: arrayNew(:)
    7418             :     end function
    7419             : #endif
    7420             : 
    7421             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7422             : 
    7423             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7424             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7425             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7426             : 
    7427             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7428             : 
    7429             : #if SK5_ENABLED
    7430             :     module function getReplacedCusComCusIns_D1_D1_D1_SK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7431             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7432             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_SK5
    7433             : #endif
    7434             :         use pm_kind, only: SKC => SK5
    7435             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    7436             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    7437             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    7438             :        !procedure(iseq_D1_D1_SK5)                               :: iseq
    7439             :         procedure(logical(LK))                                  :: iseq
    7440             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7441             :         logical(LK)             , intent(in)    , optional      :: sorted
    7442             :         logical(LK)             , intent(in)    , optional      :: unique
    7443             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    7444             :     end function
    7445             : #endif
    7446             : 
    7447             : #if SK4_ENABLED
    7448             :     module function getReplacedCusComCusIns_D1_D1_D1_SK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7449             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7450             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_SK4
    7451             : #endif
    7452             :         use pm_kind, only: SKC => SK4
    7453             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    7454             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    7455             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    7456             :        !procedure(iseq_D1_D1_SK4)                               :: iseq
    7457             :         procedure(logical(LK))                                  :: iseq
    7458             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7459             :         logical(LK)             , intent(in)    , optional      :: sorted
    7460             :         logical(LK)             , intent(in)    , optional      :: unique
    7461             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    7462             :     end function
    7463             : #endif
    7464             : 
    7465             : #if SK3_ENABLED
    7466             :     module function getReplacedCusComCusIns_D1_D1_D1_SK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7467             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7468             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_SK3
    7469             : #endif
    7470             :         use pm_kind, only: SKC => SK3
    7471             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    7472             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    7473             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    7474             :        !procedure(iseq_D1_D1_SK3)                               :: iseq
    7475             :         procedure(logical(LK))                                  :: iseq
    7476             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7477             :         logical(LK)             , intent(in)    , optional      :: sorted
    7478             :         logical(LK)             , intent(in)    , optional      :: unique
    7479             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    7480             :     end function
    7481             : #endif
    7482             : 
    7483             : #if SK2_ENABLED
    7484             :     module function getReplacedCusComCusIns_D1_D1_D1_SK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7485             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7486             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_SK2
    7487             : #endif
    7488             :         use pm_kind, only: SKC => SK2
    7489             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    7490             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    7491             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    7492             :        !procedure(iseq_D1_D1_SK2)                               :: iseq
    7493             :         procedure(logical(LK))                                  :: iseq
    7494             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7495             :         logical(LK)             , intent(in)    , optional      :: sorted
    7496             :         logical(LK)             , intent(in)    , optional      :: unique
    7497             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    7498             :     end function
    7499             : 
    7500             : #endif
    7501             : 
    7502             : #if SK1_ENABLED
    7503             :     module function getReplacedCusComCusIns_D1_D1_D1_SK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7504             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7505             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_SK1
    7506             : #endif
    7507             :         use pm_kind, only: SKC => SK1
    7508             :         character(*,SKC)        , intent(in)    , contiguous    :: array(:)
    7509             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    7510             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    7511             :        !procedure(iseq_D1_D1_SK1)                               :: iseq
    7512             :         procedure(logical(LK))                                  :: iseq
    7513             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7514             :         logical(LK)             , intent(in)    , optional      :: sorted
    7515             :         logical(LK)             , intent(in)    , optional      :: unique
    7516             :         character(LEN_ARRAY,SKC)                , allocatable   :: arrayNew(:)
    7517             :     end function
    7518             : #endif
    7519             : 
    7520             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7521             : 
    7522             : #if IK5_ENABLED
    7523             :     module function getReplacedCusComCusIns_D1_D1_D1_IK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7524             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7525             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_IK5
    7526             : #endif
    7527             :         use pm_kind, only: IKC => IK5
    7528             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    7529             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    7530             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    7531             :        !procedure(iseq_D1_D1_IK5)                               :: iseq
    7532             :         procedure(logical(LK))                                  :: iseq
    7533             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7534             :         logical(LK)             , intent(in)    , optional      :: sorted
    7535             :         logical(LK)             , intent(in)    , optional      :: unique
    7536             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    7537             :     end function
    7538             : #endif
    7539             : 
    7540             : #if IK4_ENABLED
    7541             :     module function getReplacedCusComCusIns_D1_D1_D1_IK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7542             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7543             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_IK4
    7544             : #endif
    7545             :         use pm_kind, only: IKC => IK4
    7546             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    7547             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    7548             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    7549             :        !procedure(iseq_D1_D1_IK4)                               :: iseq
    7550             :         procedure(logical(LK))                                  :: iseq
    7551             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7552             :         logical(LK)             , intent(in)    , optional      :: sorted
    7553             :         logical(LK)             , intent(in)    , optional      :: unique
    7554             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    7555             :     end function
    7556             : #endif
    7557             : 
    7558             : #if IK3_ENABLED
    7559             :     module function getReplacedCusComCusIns_D1_D1_D1_IK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7560             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7561             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_IK3
    7562             : #endif
    7563             :         use pm_kind, only: IKC => IK3
    7564             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    7565             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    7566             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    7567             :        !procedure(iseq_D1_D1_IK3)                               :: iseq
    7568             :         procedure(logical(LK))                                  :: iseq
    7569             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7570             :         logical(LK)             , intent(in)    , optional      :: sorted
    7571             :         logical(LK)             , intent(in)    , optional      :: unique
    7572             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    7573             :     end function
    7574             : #endif
    7575             : 
    7576             : #if IK2_ENABLED
    7577             :     module function getReplacedCusComCusIns_D1_D1_D1_IK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7578             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7579             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_IK2
    7580             : #endif
    7581             :         use pm_kind, only: IKC => IK2
    7582             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    7583             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    7584             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    7585             :        !procedure(iseq_D1_D1_IK2)                               :: iseq
    7586             :         procedure(logical(LK))                                  :: iseq
    7587             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7588             :         logical(LK)             , intent(in)    , optional      :: sorted
    7589             :         logical(LK)             , intent(in)    , optional      :: unique
    7590             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    7591             :     end function
    7592             : 
    7593             : #endif
    7594             : 
    7595             : #if IK1_ENABLED
    7596             :     module function getReplacedCusComCusIns_D1_D1_D1_IK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7597             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7598             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_IK1
    7599             : #endif
    7600             :         use pm_kind, only: IKC => IK1
    7601             :         integer(IKC)            , intent(in)    , contiguous    :: array(:)
    7602             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    7603             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    7604             :        !procedure(iseq_D1_D1_IK1)                               :: iseq
    7605             :         procedure(logical(LK))                                  :: iseq
    7606             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7607             :         logical(LK)             , intent(in)    , optional      :: sorted
    7608             :         logical(LK)             , intent(in)    , optional      :: unique
    7609             :         integer(IKC)                            , allocatable   :: arrayNew(:)
    7610             :     end function
    7611             : #endif
    7612             : 
    7613             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7614             : 
    7615             : #if LK5_ENABLED
    7616             :     module function getReplacedCusComCusIns_D1_D1_D1_LK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7617             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7618             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_LK5
    7619             : #endif
    7620             :         use pm_kind, only: LKC => LK5
    7621             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    7622             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    7623             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    7624             :        !procedure(iseq_D1_D1_LK5)                               :: iseq
    7625             :         procedure(logical(LK))                                  :: iseq
    7626             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7627             :         logical(LK)             , intent(in)    , optional      :: sorted
    7628             :         logical(LK)             , intent(in)    , optional      :: unique
    7629             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    7630             :     end function
    7631             : #endif
    7632             : 
    7633             : #if LK4_ENABLED
    7634             :     module function getReplacedCusComCusIns_D1_D1_D1_LK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7635             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7636             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_LK4
    7637             : #endif
    7638             :         use pm_kind, only: LKC => LK4
    7639             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    7640             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    7641             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    7642             :        !procedure(iseq_D1_D1_LK4)                               :: iseq
    7643             :         procedure(logical(LK))                                  :: iseq
    7644             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7645             :         logical(LK)             , intent(in)    , optional      :: sorted
    7646             :         logical(LK)             , intent(in)    , optional      :: unique
    7647             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    7648             :     end function
    7649             : #endif
    7650             : 
    7651             : #if LK3_ENABLED
    7652             :     module function getReplacedCusComCusIns_D1_D1_D1_LK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7653             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7654             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_LK3
    7655             : #endif
    7656             :         use pm_kind, only: LKC => LK3
    7657             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    7658             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    7659             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    7660             :        !procedure(iseq_D1_D1_LK3)                               :: iseq
    7661             :         procedure(logical(LK))                                  :: iseq
    7662             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7663             :         logical(LK)             , intent(in)    , optional      :: sorted
    7664             :         logical(LK)             , intent(in)    , optional      :: unique
    7665             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    7666             :     end function
    7667             : #endif
    7668             : 
    7669             : #if LK2_ENABLED
    7670             :     module function getReplacedCusComCusIns_D1_D1_D1_LK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7671             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7672             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_LK2
    7673             : #endif
    7674             :         use pm_kind, only: LKC => LK2
    7675             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    7676             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    7677             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    7678             :        !procedure(iseq_D1_D1_LK2)                               :: iseq
    7679             :         procedure(logical(LK))                                  :: iseq
    7680             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7681             :         logical(LK)             , intent(in)    , optional      :: sorted
    7682             :         logical(LK)             , intent(in)    , optional      :: unique
    7683             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    7684             :     end function
    7685             : 
    7686             : #endif
    7687             : 
    7688             : #if LK1_ENABLED
    7689             :     module function getReplacedCusComCusIns_D1_D1_D1_LK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7690             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7691             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_LK1
    7692             : #endif
    7693             :         use pm_kind, only: LKC => LK1
    7694             :         logical(LKC)            , intent(in)    , contiguous    :: array(:)
    7695             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    7696             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    7697             :        !procedure(iseq_D1_D1_LK1)                               :: iseq
    7698             :         procedure(logical(LK))                                  :: iseq
    7699             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7700             :         logical(LK)             , intent(in)    , optional      :: sorted
    7701             :         logical(LK)             , intent(in)    , optional      :: unique
    7702             :         logical(LKC)                            , allocatable   :: arrayNew(:)
    7703             :     end function
    7704             : #endif
    7705             : 
    7706             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7707             : 
    7708             : #if CK5_ENABLED
    7709             :     module function getReplacedCusComCusIns_D1_D1_D1_CK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7710             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7711             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_CK5
    7712             : #endif
    7713             :         use pm_kind, only: CKC => CK5
    7714             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    7715             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    7716             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    7717             :        !procedure(iseq_D1_D1_CK5)                               :: iseq
    7718             :         procedure(logical(LK))                                  :: iseq
    7719             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7720             :         logical(LK)             , intent(in)    , optional      :: sorted
    7721             :         logical(LK)             , intent(in)    , optional      :: unique
    7722             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    7723             :     end function
    7724             : #endif
    7725             : 
    7726             : #if CK4_ENABLED
    7727             :     module function getReplacedCusComCusIns_D1_D1_D1_CK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7728             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7729             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_CK4
    7730             : #endif
    7731             :         use pm_kind, only: CKC => CK4
    7732             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    7733             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    7734             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    7735             :        !procedure(iseq_D1_D1_CK4)                               :: iseq
    7736             :         procedure(logical(LK))                                  :: iseq
    7737             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7738             :         logical(LK)             , intent(in)    , optional      :: sorted
    7739             :         logical(LK)             , intent(in)    , optional      :: unique
    7740             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    7741             :     end function
    7742             : #endif
    7743             : 
    7744             : #if CK3_ENABLED
    7745             :     module function getReplacedCusComCusIns_D1_D1_D1_CK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7746             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7747             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_CK3
    7748             : #endif
    7749             :         use pm_kind, only: CKC => CK3
    7750             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    7751             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    7752             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    7753             :        !procedure(iseq_D1_D1_CK3)                               :: iseq
    7754             :         procedure(logical(LK))                                  :: iseq
    7755             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7756             :         logical(LK)             , intent(in)    , optional      :: sorted
    7757             :         logical(LK)             , intent(in)    , optional      :: unique
    7758             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    7759             :     end function
    7760             : #endif
    7761             : 
    7762             : #if CK2_ENABLED
    7763             :     module function getReplacedCusComCusIns_D1_D1_D1_CK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7764             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7765             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_CK2
    7766             : #endif
    7767             :         use pm_kind, only: CKC => CK2
    7768             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    7769             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    7770             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    7771             :        !procedure(iseq_D1_D1_CK2)                               :: iseq
    7772             :         procedure(logical(LK))                                  :: iseq
    7773             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7774             :         logical(LK)             , intent(in)    , optional      :: sorted
    7775             :         logical(LK)             , intent(in)    , optional      :: unique
    7776             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    7777             :     end function
    7778             : 
    7779             : #endif
    7780             : 
    7781             : #if CK1_ENABLED
    7782             :     module function getReplacedCusComCusIns_D1_D1_D1_CK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7783             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7784             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_CK1
    7785             : #endif
    7786             :         use pm_kind, only: CKC => CK1
    7787             :         complex(CKC)            , intent(in)    , contiguous    :: array(:)
    7788             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    7789             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    7790             :        !procedure(iseq_D1_D1_CK1)                               :: iseq
    7791             :         procedure(logical(LK))                                  :: iseq
    7792             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7793             :         logical(LK)             , intent(in)    , optional      :: sorted
    7794             :         logical(LK)             , intent(in)    , optional      :: unique
    7795             :         complex(CKC)                            , allocatable   :: arrayNew(:)
    7796             :     end function
    7797             : #endif
    7798             : 
    7799             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7800             : 
    7801             : #if RK5_ENABLED
    7802             :     module function getReplacedCusComCusIns_D1_D1_D1_RK5(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7803             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7804             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_RK5
    7805             : #endif
    7806             :         use pm_kind, only: RKC => RK5
    7807             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    7808             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    7809             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    7810             :        !procedure(iseq_D1_D1_RK5)                               :: iseq
    7811             :         procedure(logical(LK))                                  :: iseq
    7812             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7813             :         logical(LK)             , intent(in)    , optional      :: sorted
    7814             :         logical(LK)             , intent(in)    , optional      :: unique
    7815             :         real(RKC)                               , allocatable   :: arrayNew(:)
    7816             :     end function
    7817             : #endif
    7818             : 
    7819             : #if RK4_ENABLED
    7820             :     module function getReplacedCusComCusIns_D1_D1_D1_RK4(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7821             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7822             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_RK4
    7823             : #endif
    7824             :         use pm_kind, only: RKC => RK4
    7825             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    7826             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    7827             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    7828             :        !procedure(iseq_D1_D1_RK4)                               :: iseq
    7829             :         procedure(logical(LK))                                  :: iseq
    7830             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7831             :         logical(LK)             , intent(in)    , optional      :: sorted
    7832             :         logical(LK)             , intent(in)    , optional      :: unique
    7833             :         real(RKC)                               , allocatable   :: arrayNew(:)
    7834             :     end function
    7835             : #endif
    7836             : 
    7837             : #if RK3_ENABLED
    7838             :     module function getReplacedCusComCusIns_D1_D1_D1_RK3(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7839             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7840             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_RK3
    7841             : #endif
    7842             :         use pm_kind, only: RKC => RK3
    7843             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    7844             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    7845             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    7846             :        !procedure(iseq_D1_D1_RK3)                               :: iseq
    7847             :         procedure(logical(LK))                                  :: iseq
    7848             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7849             :         logical(LK)             , intent(in)    , optional      :: sorted
    7850             :         logical(LK)             , intent(in)    , optional      :: unique
    7851             :         real(RKC)                               , allocatable   :: arrayNew(:)
    7852             :     end function
    7853             : #endif
    7854             : 
    7855             : #if RK2_ENABLED
    7856             :     module function getReplacedCusComCusIns_D1_D1_D1_RK2(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7857             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7858             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_RK2
    7859             : #endif
    7860             :         use pm_kind, only: RKC => RK2
    7861             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    7862             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    7863             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    7864             :        !procedure(iseq_D1_D1_RK2)                               :: iseq
    7865             :         procedure(logical(LK))                                  :: iseq
    7866             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7867             :         logical(LK)             , intent(in)    , optional      :: sorted
    7868             :         logical(LK)             , intent(in)    , optional      :: unique
    7869             :         real(RKC)                               , allocatable   :: arrayNew(:)
    7870             :     end function
    7871             : 
    7872             : #endif
    7873             : 
    7874             : #if RK1_ENABLED
    7875             :     module function getReplacedCusComCusIns_D1_D1_D1_RK1(array, pattern, replacement, iseq, instance, sorted, unique) result(arrayNew)
    7876             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    7877             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplacedCusComCusIns_D1_D1_D1_RK1
    7878             : #endif
    7879             :         use pm_kind, only: RKC => RK1
    7880             :         real(RKC)               , intent(in)    , contiguous    :: array(:)
    7881             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    7882             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    7883             :        !procedure(iseq_D1_D1_RK1)                               :: iseq
    7884             :         procedure(logical(LK))                                  :: iseq
    7885             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
    7886             :         logical(LK)             , intent(in)    , optional      :: sorted
    7887             :         logical(LK)             , intent(in)    , optional      :: unique
    7888             :         real(RKC)                               , allocatable   :: arrayNew(:)
    7889             :     end function
    7890             : #endif
    7891             : 
    7892             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7893             : 
    7894             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7895             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7896             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7897             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7898             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7899             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7900             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7901             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7902             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7903             : 
    7904             :     end interface
    7905             : 
    7906             : !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    7907             : 
    7908             :     !>  \brief
    7909             :     !>  Replace the requested instances of the input `pattern` with the input `replacement` in the allocatable input/output `array`.
    7910             :     !>
    7911             :     !>  \details
    7912             :     !>  If an input vector of `instance` is specified, representing the specific instances of pattern to change,
    7913             :     !>  then only those specific instances will be changed.
    7914             :     !>
    7915             :     !>  \param[inout]   array       :   The input/output `allocatable` array of rank `1` of either <br>
    7916             :     !>                                  <ul>
    7917             :     !>                                      <li>    type `character` of kind \SKALL,
    7918             :     !>                                      <li>    type `logical` of kind \LKALL, or
    7919             :     !>                                      <li>    type `integer` of kind \IKALL, or
    7920             :     !>                                      <li>    type `complex` of kind \CKALL, or
    7921             :     !>                                      <li>    type `real` of kind \RKALL, or
    7922             :     !>                                  </ul>
    7923             :     !>                                  scalar `character` of kind \SKALL,<br>
    7924             :     !>                                  within which the specific instances of the input `pattern` must be replaced.<br>
    7925             :     !>                                  On output, the array will be possibly (if needed) reallocated to its new value<br>
    7926             :     !>                                  with the requested instances of `pattern` replaced with `replacement.`<br>
    7927             :     !>  \param[in]      pattern     :   The input `contiguous` array of rank `1` of the same type and kind as the input `array`,
    7928             :     !>                                  containing the pattern whose instances will have to be replaced in the input `array`.<br>
    7929             :     !>  \param[in]      replacement :   The input `contiguous` array of rank `1` of the same type and kind as the input `array`,
    7930             :     !>                                  containing the replacement that will replace in the instances of `pattern` in the input `array`.<br>
    7931             :     !>  \param          iseq        :   The `external` user-specified function that takes either two input assumed-length `character` arguments
    7932             :     !>                                  (if the input `array` is also an assumed-length `character`) or two array-valued **explicit-shape**
    7933             :     !>                                  arguments of the same type and kind as the input `array`.<br>
    7934             :     !>                                  It must return a scalar of type `logical` of default kind \LK that is `.true.` if all elements of
    7935             :     !>                                  the two input arguments are equivalent (e.g., equal) according to the user-defined criterion, otherwise, it is `.false.`.<br>
    7936             :     !>                                  The the input `array` is array-valued, then the last argument to `iseq` is the length of the input `pattern`.<br>
    7937             :     !>                                  The following illustrates the generic interface of `iseq` where `pattern` is array-valued,
    7938             :     !>                                  \code{.F90}
    7939             :     !>                                      function iseq(segment, pattern, lenPattern) result(equivalent)
    7940             :     !>                                          use pm_kind, only: IK, LK
    7941             :     !>                                          integer(IK) , intent(in)    :: lenPattern
    7942             :     !>                                          TYPE(KIND)  , intent(in)    :: segment(lenPattern), pattern(lenPattern)
    7943             :     !>                                          logical(LK)                 :: equivalent
    7944             :     !>                                      end function
    7945             :     !>                                  \endcode
    7946             :     !>                                  where `TYPE(KIND)` represents the type and kind of the input argument `array`, which can be one of the following,
    7947             :     !>                                  \code{.F90}
    7948             :     !>                                      use pm_kind, only: SK, IK, LK, CK, RK
    7949             :     !>                                      character(*, SK), intent(in)    :: segment(lenPattern), pattern(lenPattern)
    7950             :     !>                                      integer(IK)     , intent(in)    :: segment(lenPattern), pattern(lenPattern)
    7951             :     !>                                      logical(LK)     , intent(in)    :: segment(lenPattern), pattern(lenPattern)
    7952             :     !>                                      complex(CK)     , intent(in)    :: segment(lenPattern), pattern(lenPattern)
    7953             :     !>                                      real(RK)        , intent(in)    :: segment(lenPattern), pattern(lenPattern)
    7954             :     !>                                  \endcode
    7955             :     !>                                  where the kinds `SK`, `IK`, `LK`, `CK`, `RK`, can refer to any kind type parameter that is supported by the processor.<br>
    7956             :     !>                                  The following illustrates the generic interface of `iseq` where `pattern` is scalar-valued (**including Fortran scalar strings**),
    7957             :     !>                                  \code{.F90}
    7958             :     !>                                      function iseq(segment, pattern) result(equivalent)
    7959             :     !>                                          use pm_kind, only: LK
    7960             :     !>                                          TYPE(KIND)  , intent(in)    :: segment, pattern
    7961             :     !>                                          logical(LK)                 :: equivalent
    7962             :     !>                                      end function
    7963             :     !>                                  \endcode
    7964             :     !>                                  where `TYPE(KIND)` represents the type and kind of the input argument `array`, which can be one of the following,
    7965             :     !>                                  \code{.F90}
    7966             :     !>                                      character(*, SK), intent(in)    :: segment, pattern
    7967             :     !>                                      integer(IK)     , intent(in)    :: segment, pattern
    7968             :     !>                                      logical(LK)     , intent(in)    :: segment, pattern
    7969             :     !>                                      complex(CK)     , intent(in)    :: segment, pattern
    7970             :     !>                                      real(RK)        , intent(in)    :: segment, pattern
    7971             :     !>                                  \endcode
    7972             :     !>                                  where the kinds `SK`, `IK`, `LK`, `CK`, `RK`, can refer to any kind type parameter that is supported by the processor.<br>
    7973             :     !>                                  This user-defined equivalence check is extremely useful where an equivalence test other than exact identity is needed,
    7974             :     !>                                  for example, when the array segments should match the input `pattern` only within a given threshold or,
    7975             :     !>                                  when the case-sensitivity in character comparisons do not matter.<br>
    7976             :     !>                                  In such cases, user can define a custom equivalence criterion within the user-defined external function `iseq` to achieve the goal.<br>
    7977             :     !>                                  (**optional**, the default equivalence operator is `.eqv.` if the input `array` is `logical`, otherwise `==`)
    7978             :     !>  \param[in]      instance    :   The input `contiguous` array of rank `1` of type `integer` of default kind \IK,
    7979             :     !>                                  containing the instances of the input `pattern` in the input `array` that should be replaced with the input `replacement`.<br>
    7980             :     !>                                  Any element of `instance` that points to an out-of-scope instance of `pattern` in the input `array` will be ignored.<br>
    7981             :     !>                                  Any element of `instance` that is negatively valued will be counted from end of the input `array`.<br>
    7982             :     !>                                  For example, `instance = [2,-1]` requests replacing the second instance of `pattern` in `array` from the beginning and
    7983             :     !>                                  replacing the first instance of `pattern` starting from the end of `array`.<br>
    7984             :     !>                                  (**optional**, the default value corresponds to replacing all instances of `pattern` with `replacement` in `array`)
    7985             :     !>  \param[in]      sorted      :   The input `logical` of default kind \LK indicating whether the elements of the specified input `instance` are all in ascending-order.<br>
    7986             :     !>                                  This includes the negative elements of `instance` **after** they are translated to the corresponding **positive** instances from
    7987             :     !>                                  the beginning of the input `array`.<br>Setting `sorted = .true.` will lead to faster runtime of the procedure.<br>
    7988             :     !>                                  However, the onus will be strictly on the user to ensure all elements of `instance` are in ascending-order.<br>
    7989             :     !>                                  This is generally not an easy guarantee to make if there are negative elements in `instance`.<br>
    7990             :     !>                                  Therefore, set `sorted = .true.` **only if** you can guarantee the validity of the condition.<br>
    7991             :     !>                                  (**optional**, default = `.false.`. It can be present as input argument **only if** the input argument `instance` is present.)
    7992             :     !>  \param[in]      unique      :   The input `logical` of default kind \LK indicating whether the elements of the specified input `instance` are all unique.<br>
    7993             :     !>                                  This includes the negative elements of `instance` **after** they are translated to the corresponding **positive** instances from
    7994             :     !>                                  the beginning of the input `array`.<br>Setting `unique = .true.` will lead to faster runtime of the procedure.<br>
    7995             :     !>                                  However, the onus will be strictly on the user to ensure all elements of `instance` are unique.<br>
    7996             :     !>                                  This is generally not an easy guarantee to make if there are negative elements in `instance`.<br>
    7997             :     !>                                  Therefore, set `unique = .true.` **only if** you can guarantee the validity of the condition.<br>
    7998             :     !>                                  (**optional**, default = `.false.`. It can be present as input argument **only if** the input argument `instance` is present.)
    7999             :     !>
    8000             :     !>  \interface{setReplaced}
    8001             :     !>  \code{.F90}
    8002             :     !>
    8003             :     !>      use pm_arrayReplace, only: setReplaced
    8004             :     !>
    8005             :     !>      call setReplaced(array, pattern, replacement)
    8006             :     !>      call setReplaced(array, pattern, replacement, iseq)
    8007             :     !>      call setReplaced(array, pattern, replacement, instance, sorted = sorted, unique = unique)
    8008             :     !>      call setReplaced(array, pattern, replacement, iseq, instance, sorted = sorted, unique = unique)
    8009             :     !>
    8010             :     !>  \endcode
    8011             :     !>
    8012             :     !>  \warnpure
    8013             :     !>
    8014             :     !>  \warning
    8015             :     !>  The procedures under this generic interface are `impure` when the user-specified `external` procedure `iseq` is specified as input argument.<br>
    8016             :     !>
    8017             :     !>  \warning
    8018             :     !>  Note that in Fortran, trailing blanks are ignored in character comparison, that is, `"Fortran" == "Fortran "` yields `.true.`.<br>
    8019             :     !>
    8020             :     !>  \remark
    8021             :     !>  The logic behind making the argument `array` an `allocatable` with `intent(inout)` is to make the procedures potentially more efficient with a well-defined behavior.<br>
    8022             :     !>  The alternative to the current interface is to pass an extra `intent(out), allocatable :: arrayNew(:)` argument along with an `intent(in), contiguous :: array(:)`.<br>
    8023             :     !>  This, however, leads to unnecessary copies of `array` to `arrayNew` when no replacement practically has occurred.<br>
    8024             :     !>  Furthermore, the size of the output `arrayNew` must be set a priori by the user which is only determined within the algorithm.<br>
    8025             :     !>
    8026             :     !>  \remark
    8027             :     !>  The subroutines under this interface are slightly faster than the [getReplaced](@ref pm_arrayReplace::getReplaced) function implementations.<br>
    8028             :     !>  See [pm_arrayReplace](@ref pm_arrayReplace) for the relevant benchmarks.
    8029             :     !>
    8030             :     !>  \note
    8031             :     !>  The procedures under this generic interface perform replacements within the input `array` in-place.<br>
    8032             :     !>  To return the result in a new array, use [getReplaced](@ref pm_arrayReplace::getReplaced).<br>
    8033             :     !>  See [pm_arrayReplace](@ref pm_arrayReplace) for the relevant performance benchmarks.<br>
    8034             :     !>
    8035             :     !>  \note
    8036             :     !>  Upon return, the `allocatable, intent(inout) :: array` argument is guaranteed to have the same lower bound as before,
    8037             :     !>  although its upper bound is potentially different.
    8038             :     !>
    8039             :     !>  \see
    8040             :     !>  [getReplaced](@ref pm_arrayReplace::getReplaced)<br>
    8041             :     !>  [setInserted](@ref pm_arrayInsert::setInserted)<br>
    8042             :     !>  [setRemoved](@ref pm_arrayRemove::setRemoved)<br>
    8043             :     !>  [setSplit](@ref pm_arraySplit::setSplit)<br>
    8044             :     !>
    8045             :     !>  \example{setReplaced}
    8046             :     !>  \include{lineno} example/pm_arrayReplace/setReplaced/main.F90
    8047             :     !>  \compilef{setReplaced}
    8048             :     !>  \output{setReplaced}
    8049             :     !>  \include{lineno} example/pm_arrayReplace/setReplaced/main.out.F90
    8050             :     !>
    8051             :     !>  \test
    8052             :     !>  [test_pm_arrayReplace](@ref test_pm_arrayReplace)
    8053             :     !>
    8054             :     !>  \todo
    8055             :     !>  \plow This logic behind using `intent(inout), allocatable :: array` argument as opposed to returning the result
    8056             :     !>  in a new array is that the size of the output array is not known a priori, but is determined within the algorithm.<br>
    8057             :     !>  If the use of `allocatable` dummy arguments is to be truly avoided, a new interface can be added where the output is
    8058             :     !>  returned in a `contiguous` `ArrayReplaced` while the input array remains intact.<br>
    8059             :     !>
    8060             :     !>  \todo
    8061             :     !>  \plow This generic interface can be extended to 2D input objects.<br>
    8062             :     !>
    8063             :     !>  \todo
    8064             :     !>  \phigh This generic interface can be extended to scalar non-string input `pattern` and `replacement` arguments.<br>
    8065             :     !>  Such an extension will likely lead to runtime performance gain for cases where `pattern` and `replacement` are arrays of length `1`.
    8066             :     !>  See [pm_arraySplit](@ref pm_arraySplit) for an example relevant benchmark about this matter.<br>
    8067             :     !>
    8068             :     !>  \todo
    8069             :     !>  \phigh A benchmark comparing the performance of [setReplaced](@ref pm_arrayReplace::setReplaced) with and without `sorted, unique`
    8070             :     !>  optional input arguments should be added.
    8071             :     !>
    8072             :     !>  \finmain{setReplaced}
    8073             :     !>
    8074             :     !>  \author
    8075             :     !>  \AmirShahmoradi, September 1, 2017, 12:00 AM, Institute for Computational Engineering and Sciences (ICES), The University of Texas at Austin
    8076             :     interface setReplaced
    8077             : 
    8078             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8079             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8080             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8081             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8082             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8083             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8084             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8085             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8086             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8087             : 
    8088             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8089             : 
    8090             : #if SK5_ENABLED
    8091             :     PURE module subroutine setReplacedDefComDefIns_D0_D0_D0_SK5(array, pattern, replacement)
    8092             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8093             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D0_D0_D0_SK5
    8094             : #endif
    8095             :         use pm_kind, only: SKC => SK5
    8096             :         character(:,SKC)        , intent(inout) , allocatable   :: array
    8097             :         character(*,SKC)        , intent(in)                    :: pattern
    8098             :         character(*,SKC)        , intent(in)                    :: replacement
    8099             :     end subroutine
    8100             : #endif
    8101             : 
    8102             : #if SK4_ENABLED
    8103             :     PURE module subroutine setReplacedDefComDefIns_D0_D0_D0_SK4(array, pattern, replacement)
    8104             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8105             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D0_D0_D0_SK4
    8106             : #endif
    8107             :         use pm_kind, only: SKC => SK4
    8108             :         character(:,SKC)        , intent(inout) , allocatable   :: array
    8109             :         character(*,SKC)        , intent(in)                    :: pattern
    8110             :         character(*,SKC)        , intent(in)                    :: replacement
    8111             :     end subroutine
    8112             : #endif
    8113             : 
    8114             : #if SK3_ENABLED
    8115             :     PURE module subroutine setReplacedDefComDefIns_D0_D0_D0_SK3(array, pattern, replacement)
    8116             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8117             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D0_D0_D0_SK3
    8118             : #endif
    8119             :         use pm_kind, only: SKC => SK3
    8120             :         character(:,SKC)        , intent(inout) , allocatable   :: array
    8121             :         character(*,SKC)        , intent(in)                    :: pattern
    8122             :         character(*,SKC)        , intent(in)                    :: replacement
    8123             :     end subroutine
    8124             : #endif
    8125             : 
    8126             : #if SK2_ENABLED
    8127             :     PURE module subroutine setReplacedDefComDefIns_D0_D0_D0_SK2(array, pattern, replacement)
    8128             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8129             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D0_D0_D0_SK2
    8130             : #endif
    8131             :         use pm_kind, only: SKC => SK2
    8132             :         character(:,SKC)        , intent(inout) , allocatable   :: array
    8133             :         character(*,SKC)        , intent(in)                    :: pattern
    8134             :         character(*,SKC)        , intent(in)                    :: replacement
    8135             :     end subroutine
    8136             : 
    8137             : #endif
    8138             : 
    8139             : #if SK1_ENABLED
    8140             :     PURE module subroutine setReplacedDefComDefIns_D0_D0_D0_SK1(array, pattern, replacement)
    8141             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8142             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D0_D0_D0_SK1
    8143             : #endif
    8144             :         use pm_kind, only: SKC => SK1
    8145             :         character(:,SKC)        , intent(inout) , allocatable   :: array
    8146             :         character(*,SKC)        , intent(in)                    :: pattern
    8147             :         character(*,SKC)        , intent(in)                    :: replacement
    8148             :     end subroutine
    8149             : #endif
    8150             : 
    8151             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8152             : 
    8153             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8154             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8155             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8156             : 
    8157             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8158             : 
    8159             : #if SK5_ENABLED
    8160             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_SK5(array, pattern, replacement)
    8161             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8162             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_SK5
    8163             : #endif
    8164             :         use pm_kind, only: SKC => SK5
    8165             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8166             :         character(*,SKC)        , intent(in)                    :: pattern
    8167             :         character(*,SKC)        , intent(in)                    :: replacement
    8168             :     end subroutine
    8169             : #endif
    8170             : 
    8171             : #if SK4_ENABLED
    8172             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_SK4(array, pattern, replacement)
    8173             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8174             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_SK4
    8175             : #endif
    8176             :         use pm_kind, only: SKC => SK4
    8177             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8178             :         character(*,SKC)        , intent(in)                    :: pattern
    8179             :         character(*,SKC)        , intent(in)                    :: replacement
    8180             :     end subroutine
    8181             : #endif
    8182             : 
    8183             : #if SK3_ENABLED
    8184             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_SK3(array, pattern, replacement)
    8185             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8186             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_SK3
    8187             : #endif
    8188             :         use pm_kind, only: SKC => SK3
    8189             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8190             :         character(*,SKC)        , intent(in)                    :: pattern
    8191             :         character(*,SKC)        , intent(in)                    :: replacement
    8192             :     end subroutine
    8193             : #endif
    8194             : 
    8195             : #if SK2_ENABLED
    8196             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_SK2(array, pattern, replacement)
    8197             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8198             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_SK2
    8199             : #endif
    8200             :         use pm_kind, only: SKC => SK2
    8201             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8202             :         character(*,SKC)        , intent(in)                    :: pattern
    8203             :         character(*,SKC)        , intent(in)                    :: replacement
    8204             :     end subroutine
    8205             : 
    8206             : #endif
    8207             : 
    8208             : #if SK1_ENABLED
    8209             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_SK1(array, pattern, replacement)
    8210             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8211             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_SK1
    8212             : #endif
    8213             :         use pm_kind, only: SKC => SK1
    8214             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8215             :         character(*,SKC)        , intent(in)                    :: pattern
    8216             :         character(*,SKC)        , intent(in)                    :: replacement
    8217             :     end subroutine
    8218             : #endif
    8219             : 
    8220             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8221             : 
    8222             : #if IK5_ENABLED
    8223             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_IK5(array, pattern, replacement)
    8224             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8225             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_IK5
    8226             : #endif
    8227             :         use pm_kind, only: IKC => IK5
    8228             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8229             :         integer(IKC)            , intent(in)                    :: pattern
    8230             :         integer(IKC)            , intent(in)                    :: replacement
    8231             :     end subroutine
    8232             : #endif
    8233             : 
    8234             : #if IK4_ENABLED
    8235             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_IK4(array, pattern, replacement)
    8236             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8237             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_IK4
    8238             : #endif
    8239             :         use pm_kind, only: IKC => IK4
    8240             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8241             :         integer(IKC)            , intent(in)                    :: pattern
    8242             :         integer(IKC)            , intent(in)                    :: replacement
    8243             :     end subroutine
    8244             : #endif
    8245             : 
    8246             : #if IK3_ENABLED
    8247             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_IK3(array, pattern, replacement)
    8248             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8249             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_IK3
    8250             : #endif
    8251             :         use pm_kind, only: IKC => IK3
    8252             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8253             :         integer(IKC)            , intent(in)                    :: pattern
    8254             :         integer(IKC)            , intent(in)                    :: replacement
    8255             :     end subroutine
    8256             : #endif
    8257             : 
    8258             : #if IK2_ENABLED
    8259             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_IK2(array, pattern, replacement)
    8260             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8261             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_IK2
    8262             : #endif
    8263             :         use pm_kind, only: IKC => IK2
    8264             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8265             :         integer(IKC)            , intent(in)                    :: pattern
    8266             :         integer(IKC)            , intent(in)                    :: replacement
    8267             :     end subroutine
    8268             : 
    8269             : #endif
    8270             : 
    8271             : #if IK1_ENABLED
    8272             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_IK1(array, pattern, replacement)
    8273             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8274             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_IK1
    8275             : #endif
    8276             :         use pm_kind, only: IKC => IK1
    8277             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8278             :         integer(IKC)            , intent(in)                    :: pattern
    8279             :         integer(IKC)            , intent(in)                    :: replacement
    8280             :     end subroutine
    8281             : #endif
    8282             : 
    8283             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8284             : 
    8285             : #if LK5_ENABLED
    8286             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_LK5(array, pattern, replacement)
    8287             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8288             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_LK5
    8289             : #endif
    8290             :         use pm_kind, only: LKC => LK5
    8291             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8292             :         logical(LKC)            , intent(in)                    :: pattern
    8293             :         logical(LKC)            , intent(in)                    :: replacement
    8294             :     end subroutine
    8295             : #endif
    8296             : 
    8297             : #if LK4_ENABLED
    8298             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_LK4(array, pattern, replacement)
    8299             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8300             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_LK4
    8301             : #endif
    8302             :         use pm_kind, only: LKC => LK4
    8303             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8304             :         logical(LKC)            , intent(in)                    :: pattern
    8305             :         logical(LKC)            , intent(in)                    :: replacement
    8306             :     end subroutine
    8307             : #endif
    8308             : 
    8309             : #if LK3_ENABLED
    8310             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_LK3(array, pattern, replacement)
    8311             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8312             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_LK3
    8313             : #endif
    8314             :         use pm_kind, only: LKC => LK3
    8315             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8316             :         logical(LKC)            , intent(in)                    :: pattern
    8317             :         logical(LKC)            , intent(in)                    :: replacement
    8318             :     end subroutine
    8319             : #endif
    8320             : 
    8321             : #if LK2_ENABLED
    8322             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_LK2(array, pattern, replacement)
    8323             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8324             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_LK2
    8325             : #endif
    8326             :         use pm_kind, only: LKC => LK2
    8327             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8328             :         logical(LKC)            , intent(in)                    :: pattern
    8329             :         logical(LKC)            , intent(in)                    :: replacement
    8330             :     end subroutine
    8331             : 
    8332             : #endif
    8333             : 
    8334             : #if LK1_ENABLED
    8335             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_LK1(array, pattern, replacement)
    8336             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8337             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_LK1
    8338             : #endif
    8339             :         use pm_kind, only: LKC => LK1
    8340             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8341             :         logical(LKC)            , intent(in)                    :: pattern
    8342             :         logical(LKC)            , intent(in)                    :: replacement
    8343             :     end subroutine
    8344             : #endif
    8345             : 
    8346             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8347             : 
    8348             : #if CK5_ENABLED
    8349             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_CK5(array, pattern, replacement)
    8350             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8351             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_CK5
    8352             : #endif
    8353             :         use pm_kind, only: CKC => CK5
    8354             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8355             :         complex(CKC)            , intent(in)                    :: pattern
    8356             :         complex(CKC)            , intent(in)                    :: replacement
    8357             :     end subroutine
    8358             : #endif
    8359             : 
    8360             : #if CK4_ENABLED
    8361             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_CK4(array, pattern, replacement)
    8362             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8363             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_CK4
    8364             : #endif
    8365             :         use pm_kind, only: CKC => CK4
    8366             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8367             :         complex(CKC)            , intent(in)                    :: pattern
    8368             :         complex(CKC)            , intent(in)                    :: replacement
    8369             :     end subroutine
    8370             : #endif
    8371             : 
    8372             : #if CK3_ENABLED
    8373             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_CK3(array, pattern, replacement)
    8374             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8375             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_CK3
    8376             : #endif
    8377             :         use pm_kind, only: CKC => CK3
    8378             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8379             :         complex(CKC)            , intent(in)                    :: pattern
    8380             :         complex(CKC)            , intent(in)                    :: replacement
    8381             :     end subroutine
    8382             : #endif
    8383             : 
    8384             : #if CK2_ENABLED
    8385             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_CK2(array, pattern, replacement)
    8386             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8387             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_CK2
    8388             : #endif
    8389             :         use pm_kind, only: CKC => CK2
    8390             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8391             :         complex(CKC)            , intent(in)                    :: pattern
    8392             :         complex(CKC)            , intent(in)                    :: replacement
    8393             :     end subroutine
    8394             : 
    8395             : #endif
    8396             : 
    8397             : #if CK1_ENABLED
    8398             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_CK1(array, pattern, replacement)
    8399             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8400             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_CK1
    8401             : #endif
    8402             :         use pm_kind, only: CKC => CK1
    8403             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8404             :         complex(CKC)            , intent(in)                    :: pattern
    8405             :         complex(CKC)            , intent(in)                    :: replacement
    8406             :     end subroutine
    8407             : #endif
    8408             : 
    8409             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8410             : 
    8411             : #if RK5_ENABLED
    8412             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_RK5(array, pattern, replacement)
    8413             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8414             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_RK5
    8415             : #endif
    8416             :         use pm_kind, only: RKC => RK5
    8417             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    8418             :         real(RKC)               , intent(in)                    :: pattern
    8419             :         real(RKC)               , intent(in)                    :: replacement
    8420             :     end subroutine
    8421             : #endif
    8422             : 
    8423             : #if RK4_ENABLED
    8424             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_RK4(array, pattern, replacement)
    8425             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8426             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_RK4
    8427             : #endif
    8428             :         use pm_kind, only: RKC => RK4
    8429             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    8430             :         real(RKC)               , intent(in)                    :: pattern
    8431             :         real(RKC)               , intent(in)                    :: replacement
    8432             :     end subroutine
    8433             : #endif
    8434             : 
    8435             : #if RK3_ENABLED
    8436             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_RK3(array, pattern, replacement)
    8437             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8438             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_RK3
    8439             : #endif
    8440             :         use pm_kind, only: RKC => RK3
    8441             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    8442             :         real(RKC)               , intent(in)                    :: pattern
    8443             :         real(RKC)               , intent(in)                    :: replacement
    8444             :     end subroutine
    8445             : #endif
    8446             : 
    8447             : #if RK2_ENABLED
    8448             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_RK2(array, pattern, replacement)
    8449             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8450             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_RK2
    8451             : #endif
    8452             :         use pm_kind, only: RKC => RK2
    8453             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    8454             :         real(RKC)               , intent(in)                    :: pattern
    8455             :         real(RKC)               , intent(in)                    :: replacement
    8456             :     end subroutine
    8457             : 
    8458             : #endif
    8459             : 
    8460             : #if RK1_ENABLED
    8461             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D0_RK1(array, pattern, replacement)
    8462             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8463             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D0_RK1
    8464             : #endif
    8465             :         use pm_kind, only: RKC => RK1
    8466             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    8467             :         real(RKC)               , intent(in)                    :: pattern
    8468             :         real(RKC)               , intent(in)                    :: replacement
    8469             :     end subroutine
    8470             : #endif
    8471             : 
    8472             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8473             : 
    8474             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8475             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8476             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8477             : 
    8478             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8479             : 
    8480             : #if SK5_ENABLED
    8481             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_SK5(array, pattern, replacement)
    8482             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8483             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_SK5
    8484             : #endif
    8485             :         use pm_kind, only: SKC => SK5
    8486             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8487             :         character(*,SKC)        , intent(in)                    :: pattern
    8488             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    8489             :     end subroutine
    8490             : #endif
    8491             : 
    8492             : #if SK4_ENABLED
    8493             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_SK4(array, pattern, replacement)
    8494             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8495             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_SK4
    8496             : #endif
    8497             :         use pm_kind, only: SKC => SK4
    8498             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8499             :         character(*,SKC)        , intent(in)                    :: pattern
    8500             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    8501             :     end subroutine
    8502             : #endif
    8503             : 
    8504             : #if SK3_ENABLED
    8505             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_SK3(array, pattern, replacement)
    8506             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8507             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_SK3
    8508             : #endif
    8509             :         use pm_kind, only: SKC => SK3
    8510             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8511             :         character(*,SKC)        , intent(in)                    :: pattern
    8512             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    8513             :     end subroutine
    8514             : #endif
    8515             : 
    8516             : #if SK2_ENABLED
    8517             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_SK2(array, pattern, replacement)
    8518             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8519             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_SK2
    8520             : #endif
    8521             :         use pm_kind, only: SKC => SK2
    8522             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8523             :         character(*,SKC)        , intent(in)                    :: pattern
    8524             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    8525             :     end subroutine
    8526             : 
    8527             : #endif
    8528             : 
    8529             : #if SK1_ENABLED
    8530             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_SK1(array, pattern, replacement)
    8531             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8532             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_SK1
    8533             : #endif
    8534             :         use pm_kind, only: SKC => SK1
    8535             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8536             :         character(*,SKC)        , intent(in)                    :: pattern
    8537             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    8538             :     end subroutine
    8539             : #endif
    8540             : 
    8541             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8542             : 
    8543             : #if IK5_ENABLED
    8544             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_IK5(array, pattern, replacement)
    8545             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8546             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_IK5
    8547             : #endif
    8548             :         use pm_kind, only: IKC => IK5
    8549             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8550             :         integer(IKC)            , intent(in)                    :: pattern
    8551             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    8552             :     end subroutine
    8553             : #endif
    8554             : 
    8555             : #if IK4_ENABLED
    8556             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_IK4(array, pattern, replacement)
    8557             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8558             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_IK4
    8559             : #endif
    8560             :         use pm_kind, only: IKC => IK4
    8561             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8562             :         integer(IKC)            , intent(in)                    :: pattern
    8563             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    8564             :     end subroutine
    8565             : #endif
    8566             : 
    8567             : #if IK3_ENABLED
    8568             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_IK3(array, pattern, replacement)
    8569             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8570             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_IK3
    8571             : #endif
    8572             :         use pm_kind, only: IKC => IK3
    8573             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8574             :         integer(IKC)            , intent(in)                    :: pattern
    8575             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    8576             :     end subroutine
    8577             : #endif
    8578             : 
    8579             : #if IK2_ENABLED
    8580             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_IK2(array, pattern, replacement)
    8581             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8582             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_IK2
    8583             : #endif
    8584             :         use pm_kind, only: IKC => IK2
    8585             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8586             :         integer(IKC)            , intent(in)                    :: pattern
    8587             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    8588             :     end subroutine
    8589             : 
    8590             : #endif
    8591             : 
    8592             : #if IK1_ENABLED
    8593             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_IK1(array, pattern, replacement)
    8594             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8595             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_IK1
    8596             : #endif
    8597             :         use pm_kind, only: IKC => IK1
    8598             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8599             :         integer(IKC)            , intent(in)                    :: pattern
    8600             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    8601             :     end subroutine
    8602             : #endif
    8603             : 
    8604             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8605             : 
    8606             : #if LK5_ENABLED
    8607             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_LK5(array, pattern, replacement)
    8608             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8609             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_LK5
    8610             : #endif
    8611             :         use pm_kind, only: LKC => LK5
    8612             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8613             :         logical(LKC)            , intent(in)                    :: pattern
    8614             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    8615             :     end subroutine
    8616             : #endif
    8617             : 
    8618             : #if LK4_ENABLED
    8619             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_LK4(array, pattern, replacement)
    8620             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8621             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_LK4
    8622             : #endif
    8623             :         use pm_kind, only: LKC => LK4
    8624             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8625             :         logical(LKC)            , intent(in)                    :: pattern
    8626             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    8627             :     end subroutine
    8628             : #endif
    8629             : 
    8630             : #if LK3_ENABLED
    8631             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_LK3(array, pattern, replacement)
    8632             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8633             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_LK3
    8634             : #endif
    8635             :         use pm_kind, only: LKC => LK3
    8636             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8637             :         logical(LKC)            , intent(in)                    :: pattern
    8638             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    8639             :     end subroutine
    8640             : #endif
    8641             : 
    8642             : #if LK2_ENABLED
    8643             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_LK2(array, pattern, replacement)
    8644             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8645             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_LK2
    8646             : #endif
    8647             :         use pm_kind, only: LKC => LK2
    8648             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8649             :         logical(LKC)            , intent(in)                    :: pattern
    8650             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    8651             :     end subroutine
    8652             : 
    8653             : #endif
    8654             : 
    8655             : #if LK1_ENABLED
    8656             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_LK1(array, pattern, replacement)
    8657             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8658             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_LK1
    8659             : #endif
    8660             :         use pm_kind, only: LKC => LK1
    8661             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8662             :         logical(LKC)            , intent(in)                    :: pattern
    8663             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    8664             :     end subroutine
    8665             : #endif
    8666             : 
    8667             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8668             : 
    8669             : #if CK5_ENABLED
    8670             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_CK5(array, pattern, replacement)
    8671             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8672             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_CK5
    8673             : #endif
    8674             :         use pm_kind, only: CKC => CK5
    8675             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8676             :         complex(CKC)            , intent(in)                    :: pattern
    8677             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    8678             :     end subroutine
    8679             : #endif
    8680             : 
    8681             : #if CK4_ENABLED
    8682             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_CK4(array, pattern, replacement)
    8683             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8684             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_CK4
    8685             : #endif
    8686             :         use pm_kind, only: CKC => CK4
    8687             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8688             :         complex(CKC)            , intent(in)                    :: pattern
    8689             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    8690             :     end subroutine
    8691             : #endif
    8692             : 
    8693             : #if CK3_ENABLED
    8694             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_CK3(array, pattern, replacement)
    8695             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8696             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_CK3
    8697             : #endif
    8698             :         use pm_kind, only: CKC => CK3
    8699             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8700             :         complex(CKC)            , intent(in)                    :: pattern
    8701             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    8702             :     end subroutine
    8703             : #endif
    8704             : 
    8705             : #if CK2_ENABLED
    8706             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_CK2(array, pattern, replacement)
    8707             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8708             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_CK2
    8709             : #endif
    8710             :         use pm_kind, only: CKC => CK2
    8711             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8712             :         complex(CKC)            , intent(in)                    :: pattern
    8713             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    8714             :     end subroutine
    8715             : 
    8716             : #endif
    8717             : 
    8718             : #if CK1_ENABLED
    8719             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_CK1(array, pattern, replacement)
    8720             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8721             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_CK1
    8722             : #endif
    8723             :         use pm_kind, only: CKC => CK1
    8724             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8725             :         complex(CKC)            , intent(in)                    :: pattern
    8726             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    8727             :     end subroutine
    8728             : #endif
    8729             : 
    8730             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8731             : 
    8732             : #if RK5_ENABLED
    8733             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_RK5(array, pattern, replacement)
    8734             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8735             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_RK5
    8736             : #endif
    8737             :         use pm_kind, only: RKC => RK5
    8738             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    8739             :         real(RKC)               , intent(in)                    :: pattern
    8740             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    8741             :     end subroutine
    8742             : #endif
    8743             : 
    8744             : #if RK4_ENABLED
    8745             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_RK4(array, pattern, replacement)
    8746             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8747             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_RK4
    8748             : #endif
    8749             :         use pm_kind, only: RKC => RK4
    8750             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    8751             :         real(RKC)               , intent(in)                    :: pattern
    8752             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    8753             :     end subroutine
    8754             : #endif
    8755             : 
    8756             : #if RK3_ENABLED
    8757             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_RK3(array, pattern, replacement)
    8758             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8759             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_RK3
    8760             : #endif
    8761             :         use pm_kind, only: RKC => RK3
    8762             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    8763             :         real(RKC)               , intent(in)                    :: pattern
    8764             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    8765             :     end subroutine
    8766             : #endif
    8767             : 
    8768             : #if RK2_ENABLED
    8769             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_RK2(array, pattern, replacement)
    8770             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8771             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_RK2
    8772             : #endif
    8773             :         use pm_kind, only: RKC => RK2
    8774             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    8775             :         real(RKC)               , intent(in)                    :: pattern
    8776             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    8777             :     end subroutine
    8778             : 
    8779             : #endif
    8780             : 
    8781             : #if RK1_ENABLED
    8782             :     PURE module subroutine setReplacedDefComDefIns_D1_D0_D1_RK1(array, pattern, replacement)
    8783             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8784             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D0_D1_RK1
    8785             : #endif
    8786             :         use pm_kind, only: RKC => RK1
    8787             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    8788             :         real(RKC)               , intent(in)                    :: pattern
    8789             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    8790             :     end subroutine
    8791             : #endif
    8792             : 
    8793             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8794             : 
    8795             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8796             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8797             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8798             : 
    8799             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8800             : 
    8801             : #if SK5_ENABLED
    8802             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_SK5(array, pattern, replacement)
    8803             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8804             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_SK5
    8805             : #endif
    8806             :         use pm_kind, only: SKC => SK5
    8807             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8808             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    8809             :         character(*,SKC)        , intent(in)                    :: replacement
    8810             :     end subroutine
    8811             : #endif
    8812             : 
    8813             : #if SK4_ENABLED
    8814             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_SK4(array, pattern, replacement)
    8815             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8816             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_SK4
    8817             : #endif
    8818             :         use pm_kind, only: SKC => SK4
    8819             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8820             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    8821             :         character(*,SKC)        , intent(in)                    :: replacement
    8822             :     end subroutine
    8823             : #endif
    8824             : 
    8825             : #if SK3_ENABLED
    8826             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_SK3(array, pattern, replacement)
    8827             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8828             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_SK3
    8829             : #endif
    8830             :         use pm_kind, only: SKC => SK3
    8831             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8832             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    8833             :         character(*,SKC)        , intent(in)                    :: replacement
    8834             :     end subroutine
    8835             : #endif
    8836             : 
    8837             : #if SK2_ENABLED
    8838             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_SK2(array, pattern, replacement)
    8839             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8840             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_SK2
    8841             : #endif
    8842             :         use pm_kind, only: SKC => SK2
    8843             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8844             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    8845             :         character(*,SKC)        , intent(in)                    :: replacement
    8846             :     end subroutine
    8847             : 
    8848             : #endif
    8849             : 
    8850             : #if SK1_ENABLED
    8851             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_SK1(array, pattern, replacement)
    8852             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8853             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_SK1
    8854             : #endif
    8855             :         use pm_kind, only: SKC => SK1
    8856             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    8857             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    8858             :         character(*,SKC)        , intent(in)                    :: replacement
    8859             :     end subroutine
    8860             : #endif
    8861             : 
    8862             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8863             : 
    8864             : #if IK5_ENABLED
    8865             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_IK5(array, pattern, replacement)
    8866             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8867             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_IK5
    8868             : #endif
    8869             :         use pm_kind, only: IKC => IK5
    8870             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8871             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    8872             :         integer(IKC)            , intent(in)                    :: replacement
    8873             :     end subroutine
    8874             : #endif
    8875             : 
    8876             : #if IK4_ENABLED
    8877             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_IK4(array, pattern, replacement)
    8878             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8879             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_IK4
    8880             : #endif
    8881             :         use pm_kind, only: IKC => IK4
    8882             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8883             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    8884             :         integer(IKC)            , intent(in)                    :: replacement
    8885             :     end subroutine
    8886             : #endif
    8887             : 
    8888             : #if IK3_ENABLED
    8889             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_IK3(array, pattern, replacement)
    8890             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8891             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_IK3
    8892             : #endif
    8893             :         use pm_kind, only: IKC => IK3
    8894             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8895             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    8896             :         integer(IKC)            , intent(in)                    :: replacement
    8897             :     end subroutine
    8898             : #endif
    8899             : 
    8900             : #if IK2_ENABLED
    8901             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_IK2(array, pattern, replacement)
    8902             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8903             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_IK2
    8904             : #endif
    8905             :         use pm_kind, only: IKC => IK2
    8906             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8907             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    8908             :         integer(IKC)            , intent(in)                    :: replacement
    8909             :     end subroutine
    8910             : 
    8911             : #endif
    8912             : 
    8913             : #if IK1_ENABLED
    8914             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_IK1(array, pattern, replacement)
    8915             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8916             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_IK1
    8917             : #endif
    8918             :         use pm_kind, only: IKC => IK1
    8919             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    8920             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    8921             :         integer(IKC)            , intent(in)                    :: replacement
    8922             :     end subroutine
    8923             : #endif
    8924             : 
    8925             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8926             : 
    8927             : #if LK5_ENABLED
    8928             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_LK5(array, pattern, replacement)
    8929             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8930             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_LK5
    8931             : #endif
    8932             :         use pm_kind, only: LKC => LK5
    8933             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8934             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    8935             :         logical(LKC)            , intent(in)                    :: replacement
    8936             :     end subroutine
    8937             : #endif
    8938             : 
    8939             : #if LK4_ENABLED
    8940             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_LK4(array, pattern, replacement)
    8941             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8942             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_LK4
    8943             : #endif
    8944             :         use pm_kind, only: LKC => LK4
    8945             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8946             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    8947             :         logical(LKC)            , intent(in)                    :: replacement
    8948             :     end subroutine
    8949             : #endif
    8950             : 
    8951             : #if LK3_ENABLED
    8952             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_LK3(array, pattern, replacement)
    8953             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8954             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_LK3
    8955             : #endif
    8956             :         use pm_kind, only: LKC => LK3
    8957             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8958             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    8959             :         logical(LKC)            , intent(in)                    :: replacement
    8960             :     end subroutine
    8961             : #endif
    8962             : 
    8963             : #if LK2_ENABLED
    8964             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_LK2(array, pattern, replacement)
    8965             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8966             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_LK2
    8967             : #endif
    8968             :         use pm_kind, only: LKC => LK2
    8969             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8970             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    8971             :         logical(LKC)            , intent(in)                    :: replacement
    8972             :     end subroutine
    8973             : 
    8974             : #endif
    8975             : 
    8976             : #if LK1_ENABLED
    8977             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_LK1(array, pattern, replacement)
    8978             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8979             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_LK1
    8980             : #endif
    8981             :         use pm_kind, only: LKC => LK1
    8982             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    8983             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    8984             :         logical(LKC)            , intent(in)                    :: replacement
    8985             :     end subroutine
    8986             : #endif
    8987             : 
    8988             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    8989             : 
    8990             : #if CK5_ENABLED
    8991             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_CK5(array, pattern, replacement)
    8992             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    8993             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_CK5
    8994             : #endif
    8995             :         use pm_kind, only: CKC => CK5
    8996             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    8997             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    8998             :         complex(CKC)            , intent(in)                    :: replacement
    8999             :     end subroutine
    9000             : #endif
    9001             : 
    9002             : #if CK4_ENABLED
    9003             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_CK4(array, pattern, replacement)
    9004             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9005             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_CK4
    9006             : #endif
    9007             :         use pm_kind, only: CKC => CK4
    9008             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9009             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    9010             :         complex(CKC)            , intent(in)                    :: replacement
    9011             :     end subroutine
    9012             : #endif
    9013             : 
    9014             : #if CK3_ENABLED
    9015             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_CK3(array, pattern, replacement)
    9016             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9017             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_CK3
    9018             : #endif
    9019             :         use pm_kind, only: CKC => CK3
    9020             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9021             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    9022             :         complex(CKC)            , intent(in)                    :: replacement
    9023             :     end subroutine
    9024             : #endif
    9025             : 
    9026             : #if CK2_ENABLED
    9027             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_CK2(array, pattern, replacement)
    9028             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9029             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_CK2
    9030             : #endif
    9031             :         use pm_kind, only: CKC => CK2
    9032             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9033             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    9034             :         complex(CKC)            , intent(in)                    :: replacement
    9035             :     end subroutine
    9036             : 
    9037             : #endif
    9038             : 
    9039             : #if CK1_ENABLED
    9040             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_CK1(array, pattern, replacement)
    9041             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9042             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_CK1
    9043             : #endif
    9044             :         use pm_kind, only: CKC => CK1
    9045             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9046             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    9047             :         complex(CKC)            , intent(in)                    :: replacement
    9048             :     end subroutine
    9049             : #endif
    9050             : 
    9051             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9052             : 
    9053             : #if RK5_ENABLED
    9054             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_RK5(array, pattern, replacement)
    9055             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9056             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_RK5
    9057             : #endif
    9058             :         use pm_kind, only: RKC => RK5
    9059             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9060             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    9061             :         real(RKC)               , intent(in)                    :: replacement
    9062             :     end subroutine
    9063             : #endif
    9064             : 
    9065             : #if RK4_ENABLED
    9066             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_RK4(array, pattern, replacement)
    9067             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9068             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_RK4
    9069             : #endif
    9070             :         use pm_kind, only: RKC => RK4
    9071             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9072             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    9073             :         real(RKC)               , intent(in)                    :: replacement
    9074             :     end subroutine
    9075             : #endif
    9076             : 
    9077             : #if RK3_ENABLED
    9078             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_RK3(array, pattern, replacement)
    9079             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9080             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_RK3
    9081             : #endif
    9082             :         use pm_kind, only: RKC => RK3
    9083             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9084             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    9085             :         real(RKC)               , intent(in)                    :: replacement
    9086             :     end subroutine
    9087             : #endif
    9088             : 
    9089             : #if RK2_ENABLED
    9090             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_RK2(array, pattern, replacement)
    9091             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9092             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_RK2
    9093             : #endif
    9094             :         use pm_kind, only: RKC => RK2
    9095             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9096             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    9097             :         real(RKC)               , intent(in)                    :: replacement
    9098             :     end subroutine
    9099             : 
    9100             : #endif
    9101             : 
    9102             : #if RK1_ENABLED
    9103             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D0_RK1(array, pattern, replacement)
    9104             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9105             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D0_RK1
    9106             : #endif
    9107             :         use pm_kind, only: RKC => RK1
    9108             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9109             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    9110             :         real(RKC)               , intent(in)                    :: replacement
    9111             :     end subroutine
    9112             : #endif
    9113             : 
    9114             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9115             : 
    9116             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9117             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9118             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9119             : 
    9120             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9121             : 
    9122             : #if SK5_ENABLED
    9123             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_SK5(array, pattern, replacement)
    9124             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9125             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_SK5
    9126             : #endif
    9127             :         use pm_kind, only: SKC => SK5
    9128             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9129             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    9130             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    9131             :     end subroutine
    9132             : #endif
    9133             : 
    9134             : #if SK4_ENABLED
    9135             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_SK4(array, pattern, replacement)
    9136             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9137             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_SK4
    9138             : #endif
    9139             :         use pm_kind, only: SKC => SK4
    9140             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9141             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    9142             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    9143             :     end subroutine
    9144             : #endif
    9145             : 
    9146             : #if SK3_ENABLED
    9147             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_SK3(array, pattern, replacement)
    9148             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9149             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_SK3
    9150             : #endif
    9151             :         use pm_kind, only: SKC => SK3
    9152             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9153             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    9154             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    9155             :     end subroutine
    9156             : #endif
    9157             : 
    9158             : #if SK2_ENABLED
    9159             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_SK2(array, pattern, replacement)
    9160             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9161             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_SK2
    9162             : #endif
    9163             :         use pm_kind, only: SKC => SK2
    9164             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9165             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    9166             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    9167             :     end subroutine
    9168             : 
    9169             : #endif
    9170             : 
    9171             : #if SK1_ENABLED
    9172             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_SK1(array, pattern, replacement)
    9173             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9174             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_SK1
    9175             : #endif
    9176             :         use pm_kind, only: SKC => SK1
    9177             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9178             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
    9179             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    9180             :     end subroutine
    9181             : #endif
    9182             : 
    9183             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9184             : 
    9185             : #if IK5_ENABLED
    9186             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_IK5(array, pattern, replacement)
    9187             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9188             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_IK5
    9189             : #endif
    9190             :         use pm_kind, only: IKC => IK5
    9191             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9192             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    9193             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    9194             :     end subroutine
    9195             : #endif
    9196             : 
    9197             : #if IK4_ENABLED
    9198             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_IK4(array, pattern, replacement)
    9199             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9200             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_IK4
    9201             : #endif
    9202             :         use pm_kind, only: IKC => IK4
    9203             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9204             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    9205             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    9206             :     end subroutine
    9207             : #endif
    9208             : 
    9209             : #if IK3_ENABLED
    9210             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_IK3(array, pattern, replacement)
    9211             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9212             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_IK3
    9213             : #endif
    9214             :         use pm_kind, only: IKC => IK3
    9215             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9216             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    9217             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    9218             :     end subroutine
    9219             : #endif
    9220             : 
    9221             : #if IK2_ENABLED
    9222             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_IK2(array, pattern, replacement)
    9223             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9224             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_IK2
    9225             : #endif
    9226             :         use pm_kind, only: IKC => IK2
    9227             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9228             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    9229             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    9230             :     end subroutine
    9231             : 
    9232             : #endif
    9233             : 
    9234             : #if IK1_ENABLED
    9235             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_IK1(array, pattern, replacement)
    9236             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9237             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_IK1
    9238             : #endif
    9239             :         use pm_kind, only: IKC => IK1
    9240             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9241             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
    9242             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    9243             :     end subroutine
    9244             : #endif
    9245             : 
    9246             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9247             : 
    9248             : #if LK5_ENABLED
    9249             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_LK5(array, pattern, replacement)
    9250             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9251             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_LK5
    9252             : #endif
    9253             :         use pm_kind, only: LKC => LK5
    9254             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    9255             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    9256             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    9257             :     end subroutine
    9258             : #endif
    9259             : 
    9260             : #if LK4_ENABLED
    9261             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_LK4(array, pattern, replacement)
    9262             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9263             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_LK4
    9264             : #endif
    9265             :         use pm_kind, only: LKC => LK4
    9266             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    9267             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    9268             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    9269             :     end subroutine
    9270             : #endif
    9271             : 
    9272             : #if LK3_ENABLED
    9273             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_LK3(array, pattern, replacement)
    9274             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9275             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_LK3
    9276             : #endif
    9277             :         use pm_kind, only: LKC => LK3
    9278             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    9279             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    9280             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    9281             :     end subroutine
    9282             : #endif
    9283             : 
    9284             : #if LK2_ENABLED
    9285             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_LK2(array, pattern, replacement)
    9286             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9287             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_LK2
    9288             : #endif
    9289             :         use pm_kind, only: LKC => LK2
    9290             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    9291             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    9292             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    9293             :     end subroutine
    9294             : 
    9295             : #endif
    9296             : 
    9297             : #if LK1_ENABLED
    9298             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_LK1(array, pattern, replacement)
    9299             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9300             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_LK1
    9301             : #endif
    9302             :         use pm_kind, only: LKC => LK1
    9303             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    9304             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
    9305             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
    9306             :     end subroutine
    9307             : #endif
    9308             : 
    9309             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9310             : 
    9311             : #if CK5_ENABLED
    9312             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_CK5(array, pattern, replacement)
    9313             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9314             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_CK5
    9315             : #endif
    9316             :         use pm_kind, only: CKC => CK5
    9317             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9318             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    9319             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    9320             :     end subroutine
    9321             : #endif
    9322             : 
    9323             : #if CK4_ENABLED
    9324             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_CK4(array, pattern, replacement)
    9325             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9326             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_CK4
    9327             : #endif
    9328             :         use pm_kind, only: CKC => CK4
    9329             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9330             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    9331             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    9332             :     end subroutine
    9333             : #endif
    9334             : 
    9335             : #if CK3_ENABLED
    9336             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_CK3(array, pattern, replacement)
    9337             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9338             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_CK3
    9339             : #endif
    9340             :         use pm_kind, only: CKC => CK3
    9341             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9342             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    9343             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    9344             :     end subroutine
    9345             : #endif
    9346             : 
    9347             : #if CK2_ENABLED
    9348             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_CK2(array, pattern, replacement)
    9349             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9350             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_CK2
    9351             : #endif
    9352             :         use pm_kind, only: CKC => CK2
    9353             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9354             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    9355             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    9356             :     end subroutine
    9357             : 
    9358             : #endif
    9359             : 
    9360             : #if CK1_ENABLED
    9361             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_CK1(array, pattern, replacement)
    9362             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9363             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_CK1
    9364             : #endif
    9365             :         use pm_kind, only: CKC => CK1
    9366             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9367             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
    9368             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
    9369             :     end subroutine
    9370             : #endif
    9371             : 
    9372             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9373             : 
    9374             : #if RK5_ENABLED
    9375             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_RK5(array, pattern, replacement)
    9376             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9377             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_RK5
    9378             : #endif
    9379             :         use pm_kind, only: RKC => RK5
    9380             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9381             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    9382             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    9383             :     end subroutine
    9384             : #endif
    9385             : 
    9386             : #if RK4_ENABLED
    9387             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_RK4(array, pattern, replacement)
    9388             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9389             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_RK4
    9390             : #endif
    9391             :         use pm_kind, only: RKC => RK4
    9392             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9393             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    9394             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    9395             :     end subroutine
    9396             : #endif
    9397             : 
    9398             : #if RK3_ENABLED
    9399             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_RK3(array, pattern, replacement)
    9400             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9401             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_RK3
    9402             : #endif
    9403             :         use pm_kind, only: RKC => RK3
    9404             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9405             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    9406             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    9407             :     end subroutine
    9408             : #endif
    9409             : 
    9410             : #if RK2_ENABLED
    9411             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_RK2(array, pattern, replacement)
    9412             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9413             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_RK2
    9414             : #endif
    9415             :         use pm_kind, only: RKC => RK2
    9416             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9417             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    9418             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    9419             :     end subroutine
    9420             : 
    9421             : #endif
    9422             : 
    9423             : #if RK1_ENABLED
    9424             :     PURE module subroutine setReplacedDefComDefIns_D1_D1_D1_RK1(array, pattern, replacement)
    9425             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9426             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComDefIns_D1_D1_D1_RK1
    9427             : #endif
    9428             :         use pm_kind, only: RKC => RK1
    9429             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9430             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
    9431             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
    9432             :     end subroutine
    9433             : #endif
    9434             : 
    9435             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9436             : 
    9437             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9438             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9439             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9440             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9441             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9442             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9443             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9444             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9445             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9446             : 
    9447             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9448             : 
    9449             : #if SK5_ENABLED
    9450             :     module subroutine setReplacedCusComDefIns_D0_D0_D0_SK5(array, pattern, replacement, iseq)
    9451             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9452             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D0_D0_D0_SK5
    9453             : #endif
    9454             :         use pm_kind, only: SKC => SK5
    9455             :         character(:,SKC)        , intent(inout) , allocatable   :: array
    9456             :         character(*,SKC)        , intent(in)                    :: pattern
    9457             :         character(*,SKC)        , intent(in)                    :: replacement
    9458             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
    9459             :         procedure(logical(LK))                                  :: iseq
    9460             :     end subroutine
    9461             : #endif
    9462             : 
    9463             : #if SK4_ENABLED
    9464             :     module subroutine setReplacedCusComDefIns_D0_D0_D0_SK4(array, pattern, replacement, iseq)
    9465             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9466             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D0_D0_D0_SK4
    9467             : #endif
    9468             :         use pm_kind, only: SKC => SK4
    9469             :         character(:,SKC)        , intent(inout) , allocatable   :: array
    9470             :         character(*,SKC)        , intent(in)                    :: pattern
    9471             :         character(*,SKC)        , intent(in)                    :: replacement
    9472             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
    9473             :         procedure(logical(LK))                                  :: iseq
    9474             :     end subroutine
    9475             : #endif
    9476             : 
    9477             : #if SK3_ENABLED
    9478             :     module subroutine setReplacedCusComDefIns_D0_D0_D0_SK3(array, pattern, replacement, iseq)
    9479             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9480             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D0_D0_D0_SK3
    9481             : #endif
    9482             :         use pm_kind, only: SKC => SK3
    9483             :         character(:,SKC)        , intent(inout) , allocatable   :: array
    9484             :         character(*,SKC)        , intent(in)                    :: pattern
    9485             :         character(*,SKC)        , intent(in)                    :: replacement
    9486             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
    9487             :         procedure(logical(LK))                                  :: iseq
    9488             :     end subroutine
    9489             : #endif
    9490             : 
    9491             : #if SK2_ENABLED
    9492             :     module subroutine setReplacedCusComDefIns_D0_D0_D0_SK2(array, pattern, replacement, iseq)
    9493             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9494             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D0_D0_D0_SK2
    9495             : #endif
    9496             :         use pm_kind, only: SKC => SK2
    9497             :         character(:,SKC)        , intent(inout) , allocatable   :: array
    9498             :         character(*,SKC)        , intent(in)                    :: pattern
    9499             :         character(*,SKC)        , intent(in)                    :: replacement
    9500             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
    9501             :         procedure(logical(LK))                                  :: iseq
    9502             :     end subroutine
    9503             : 
    9504             : #endif
    9505             : 
    9506             : #if SK1_ENABLED
    9507             :     module subroutine setReplacedCusComDefIns_D0_D0_D0_SK1(array, pattern, replacement, iseq)
    9508             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9509             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D0_D0_D0_SK1
    9510             : #endif
    9511             :         use pm_kind, only: SKC => SK1
    9512             :         character(:,SKC)        , intent(inout) , allocatable   :: array
    9513             :         character(*,SKC)        , intent(in)                    :: pattern
    9514             :         character(*,SKC)        , intent(in)                    :: replacement
    9515             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
    9516             :         procedure(logical(LK))                                  :: iseq
    9517             :     end subroutine
    9518             : #endif
    9519             : 
    9520             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9521             : 
    9522             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9523             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9524             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9525             : 
    9526             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9527             : 
    9528             : #if SK5_ENABLED
    9529             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_SK5(array, pattern, replacement, iseq)
    9530             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9531             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_SK5
    9532             : #endif
    9533             :         use pm_kind, only: SKC => SK5
    9534             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9535             :         character(*,SKC)        , intent(in)                    :: pattern
    9536             :         character(*,SKC)        , intent(in)                    :: replacement
    9537             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
    9538             :         procedure(logical(LK))                                  :: iseq
    9539             :     end subroutine
    9540             : #endif
    9541             : 
    9542             : #if SK4_ENABLED
    9543             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_SK4(array, pattern, replacement, iseq)
    9544             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9545             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_SK4
    9546             : #endif
    9547             :         use pm_kind, only: SKC => SK4
    9548             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9549             :         character(*,SKC)        , intent(in)                    :: pattern
    9550             :         character(*,SKC)        , intent(in)                    :: replacement
    9551             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
    9552             :         procedure(logical(LK))                                  :: iseq
    9553             :     end subroutine
    9554             : #endif
    9555             : 
    9556             : #if SK3_ENABLED
    9557             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_SK3(array, pattern, replacement, iseq)
    9558             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9559             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_SK3
    9560             : #endif
    9561             :         use pm_kind, only: SKC => SK3
    9562             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9563             :         character(*,SKC)        , intent(in)                    :: pattern
    9564             :         character(*,SKC)        , intent(in)                    :: replacement
    9565             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
    9566             :         procedure(logical(LK))                                  :: iseq
    9567             :     end subroutine
    9568             : #endif
    9569             : 
    9570             : #if SK2_ENABLED
    9571             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_SK2(array, pattern, replacement, iseq)
    9572             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9573             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_SK2
    9574             : #endif
    9575             :         use pm_kind, only: SKC => SK2
    9576             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9577             :         character(*,SKC)        , intent(in)                    :: pattern
    9578             :         character(*,SKC)        , intent(in)                    :: replacement
    9579             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
    9580             :         procedure(logical(LK))                                  :: iseq
    9581             :     end subroutine
    9582             : 
    9583             : #endif
    9584             : 
    9585             : #if SK1_ENABLED
    9586             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_SK1(array, pattern, replacement, iseq)
    9587             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9588             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_SK1
    9589             : #endif
    9590             :         use pm_kind, only: SKC => SK1
    9591             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9592             :         character(*,SKC)        , intent(in)                    :: pattern
    9593             :         character(*,SKC)        , intent(in)                    :: replacement
    9594             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
    9595             :         procedure(logical(LK))                                  :: iseq
    9596             :     end subroutine
    9597             : #endif
    9598             : 
    9599             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9600             : 
    9601             : #if IK5_ENABLED
    9602             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_IK5(array, pattern, replacement, iseq)
    9603             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9604             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_IK5
    9605             : #endif
    9606             :         use pm_kind, only: IKC => IK5
    9607             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9608             :         integer(IKC)            , intent(in)                    :: pattern
    9609             :         integer(IKC)            , intent(in)                    :: replacement
    9610             :        !procedure(iseq_D0_D0_IK5)                               :: iseq
    9611             :         procedure(logical(LK))                                  :: iseq
    9612             :     end subroutine
    9613             : #endif
    9614             : 
    9615             : #if IK4_ENABLED
    9616             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_IK4(array, pattern, replacement, iseq)
    9617             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9618             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_IK4
    9619             : #endif
    9620             :         use pm_kind, only: IKC => IK4
    9621             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9622             :         integer(IKC)            , intent(in)                    :: pattern
    9623             :         integer(IKC)            , intent(in)                    :: replacement
    9624             :        !procedure(iseq_D0_D0_IK4)                               :: iseq
    9625             :         procedure(logical(LK))                                  :: iseq
    9626             :     end subroutine
    9627             : #endif
    9628             : 
    9629             : #if IK3_ENABLED
    9630             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_IK3(array, pattern, replacement, iseq)
    9631             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9632             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_IK3
    9633             : #endif
    9634             :         use pm_kind, only: IKC => IK3
    9635             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9636             :         integer(IKC)            , intent(in)                    :: pattern
    9637             :         integer(IKC)            , intent(in)                    :: replacement
    9638             :        !procedure(iseq_D0_D0_IK3)                               :: iseq
    9639             :         procedure(logical(LK))                                  :: iseq
    9640             :     end subroutine
    9641             : #endif
    9642             : 
    9643             : #if IK2_ENABLED
    9644             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_IK2(array, pattern, replacement, iseq)
    9645             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9646             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_IK2
    9647             : #endif
    9648             :         use pm_kind, only: IKC => IK2
    9649             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9650             :         integer(IKC)            , intent(in)                    :: pattern
    9651             :         integer(IKC)            , intent(in)                    :: replacement
    9652             :        !procedure(iseq_D0_D0_IK2)                               :: iseq
    9653             :         procedure(logical(LK))                                  :: iseq
    9654             :     end subroutine
    9655             : 
    9656             : #endif
    9657             : 
    9658             : #if IK1_ENABLED
    9659             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_IK1(array, pattern, replacement, iseq)
    9660             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9661             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_IK1
    9662             : #endif
    9663             :         use pm_kind, only: IKC => IK1
    9664             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9665             :         integer(IKC)            , intent(in)                    :: pattern
    9666             :         integer(IKC)            , intent(in)                    :: replacement
    9667             :        !procedure(iseq_D0_D0_IK1)                               :: iseq
    9668             :         procedure(logical(LK))                                  :: iseq
    9669             :     end subroutine
    9670             : #endif
    9671             : 
    9672             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9673             : 
    9674             : #if LK5_ENABLED
    9675             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_LK5(array, pattern, replacement, iseq)
    9676             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9677             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_LK5
    9678             : #endif
    9679             :         use pm_kind, only: LKC => LK5
    9680             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    9681             :         logical(LKC)            , intent(in)                    :: pattern
    9682             :         logical(LKC)            , intent(in)                    :: replacement
    9683             :        !procedure(iseq_D0_D0_LK5)                               :: iseq
    9684             :         procedure(logical(LK))                                  :: iseq
    9685             :     end subroutine
    9686             : #endif
    9687             : 
    9688             : #if LK4_ENABLED
    9689             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_LK4(array, pattern, replacement, iseq)
    9690             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9691             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_LK4
    9692             : #endif
    9693             :         use pm_kind, only: LKC => LK4
    9694             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    9695             :         logical(LKC)            , intent(in)                    :: pattern
    9696             :         logical(LKC)            , intent(in)                    :: replacement
    9697             :        !procedure(iseq_D0_D0_LK4)                               :: iseq
    9698             :         procedure(logical(LK))                                  :: iseq
    9699             :     end subroutine
    9700             : #endif
    9701             : 
    9702             : #if LK3_ENABLED
    9703             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_LK3(array, pattern, replacement, iseq)
    9704             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9705             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_LK3
    9706             : #endif
    9707             :         use pm_kind, only: LKC => LK3
    9708             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    9709             :         logical(LKC)            , intent(in)                    :: pattern
    9710             :         logical(LKC)            , intent(in)                    :: replacement
    9711             :        !procedure(iseq_D0_D0_LK3)                               :: iseq
    9712             :         procedure(logical(LK))                                  :: iseq
    9713             :     end subroutine
    9714             : #endif
    9715             : 
    9716             : #if LK2_ENABLED
    9717             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_LK2(array, pattern, replacement, iseq)
    9718             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9719             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_LK2
    9720             : #endif
    9721             :         use pm_kind, only: LKC => LK2
    9722             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    9723             :         logical(LKC)            , intent(in)                    :: pattern
    9724             :         logical(LKC)            , intent(in)                    :: replacement
    9725             :        !procedure(iseq_D0_D0_LK2)                               :: iseq
    9726             :         procedure(logical(LK))                                  :: iseq
    9727             :     end subroutine
    9728             : 
    9729             : #endif
    9730             : 
    9731             : #if LK1_ENABLED
    9732             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_LK1(array, pattern, replacement, iseq)
    9733             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9734             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_LK1
    9735             : #endif
    9736             :         use pm_kind, only: LKC => LK1
    9737             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
    9738             :         logical(LKC)            , intent(in)                    :: pattern
    9739             :         logical(LKC)            , intent(in)                    :: replacement
    9740             :        !procedure(iseq_D0_D0_LK1)                               :: iseq
    9741             :         procedure(logical(LK))                                  :: iseq
    9742             :     end subroutine
    9743             : #endif
    9744             : 
    9745             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9746             : 
    9747             : #if CK5_ENABLED
    9748             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_CK5(array, pattern, replacement, iseq)
    9749             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9750             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_CK5
    9751             : #endif
    9752             :         use pm_kind, only: CKC => CK5
    9753             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9754             :         complex(CKC)            , intent(in)                    :: pattern
    9755             :         complex(CKC)            , intent(in)                    :: replacement
    9756             :        !procedure(iseq_D0_D0_CK5)                               :: iseq
    9757             :         procedure(logical(LK))                                  :: iseq
    9758             :     end subroutine
    9759             : #endif
    9760             : 
    9761             : #if CK4_ENABLED
    9762             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_CK4(array, pattern, replacement, iseq)
    9763             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9764             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_CK4
    9765             : #endif
    9766             :         use pm_kind, only: CKC => CK4
    9767             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9768             :         complex(CKC)            , intent(in)                    :: pattern
    9769             :         complex(CKC)            , intent(in)                    :: replacement
    9770             :        !procedure(iseq_D0_D0_CK4)                               :: iseq
    9771             :         procedure(logical(LK))                                  :: iseq
    9772             :     end subroutine
    9773             : #endif
    9774             : 
    9775             : #if CK3_ENABLED
    9776             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_CK3(array, pattern, replacement, iseq)
    9777             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9778             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_CK3
    9779             : #endif
    9780             :         use pm_kind, only: CKC => CK3
    9781             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9782             :         complex(CKC)            , intent(in)                    :: pattern
    9783             :         complex(CKC)            , intent(in)                    :: replacement
    9784             :        !procedure(iseq_D0_D0_CK3)                               :: iseq
    9785             :         procedure(logical(LK))                                  :: iseq
    9786             :     end subroutine
    9787             : #endif
    9788             : 
    9789             : #if CK2_ENABLED
    9790             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_CK2(array, pattern, replacement, iseq)
    9791             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9792             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_CK2
    9793             : #endif
    9794             :         use pm_kind, only: CKC => CK2
    9795             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9796             :         complex(CKC)            , intent(in)                    :: pattern
    9797             :         complex(CKC)            , intent(in)                    :: replacement
    9798             :        !procedure(iseq_D0_D0_CK2)                               :: iseq
    9799             :         procedure(logical(LK))                                  :: iseq
    9800             :     end subroutine
    9801             : 
    9802             : #endif
    9803             : 
    9804             : #if CK1_ENABLED
    9805             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_CK1(array, pattern, replacement, iseq)
    9806             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9807             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_CK1
    9808             : #endif
    9809             :         use pm_kind, only: CKC => CK1
    9810             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
    9811             :         complex(CKC)            , intent(in)                    :: pattern
    9812             :         complex(CKC)            , intent(in)                    :: replacement
    9813             :        !procedure(iseq_D0_D0_CK1)                               :: iseq
    9814             :         procedure(logical(LK))                                  :: iseq
    9815             :     end subroutine
    9816             : #endif
    9817             : 
    9818             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9819             : 
    9820             : #if RK5_ENABLED
    9821             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_RK5(array, pattern, replacement, iseq)
    9822             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9823             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_RK5
    9824             : #endif
    9825             :         use pm_kind, only: RKC => RK5
    9826             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9827             :         real(RKC)               , intent(in)                    :: pattern
    9828             :         real(RKC)               , intent(in)                    :: replacement
    9829             :        !procedure(iseq_D0_D0_RK5)                               :: iseq
    9830             :         procedure(logical(LK))                                  :: iseq
    9831             :     end subroutine
    9832             : #endif
    9833             : 
    9834             : #if RK4_ENABLED
    9835             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_RK4(array, pattern, replacement, iseq)
    9836             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9837             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_RK4
    9838             : #endif
    9839             :         use pm_kind, only: RKC => RK4
    9840             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9841             :         real(RKC)               , intent(in)                    :: pattern
    9842             :         real(RKC)               , intent(in)                    :: replacement
    9843             :        !procedure(iseq_D0_D0_RK4)                               :: iseq
    9844             :         procedure(logical(LK))                                  :: iseq
    9845             :     end subroutine
    9846             : #endif
    9847             : 
    9848             : #if RK3_ENABLED
    9849             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_RK3(array, pattern, replacement, iseq)
    9850             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9851             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_RK3
    9852             : #endif
    9853             :         use pm_kind, only: RKC => RK3
    9854             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9855             :         real(RKC)               , intent(in)                    :: pattern
    9856             :         real(RKC)               , intent(in)                    :: replacement
    9857             :        !procedure(iseq_D0_D0_RK3)                               :: iseq
    9858             :         procedure(logical(LK))                                  :: iseq
    9859             :     end subroutine
    9860             : #endif
    9861             : 
    9862             : #if RK2_ENABLED
    9863             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_RK2(array, pattern, replacement, iseq)
    9864             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9865             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_RK2
    9866             : #endif
    9867             :         use pm_kind, only: RKC => RK2
    9868             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9869             :         real(RKC)               , intent(in)                    :: pattern
    9870             :         real(RKC)               , intent(in)                    :: replacement
    9871             :        !procedure(iseq_D0_D0_RK2)                               :: iseq
    9872             :         procedure(logical(LK))                                  :: iseq
    9873             :     end subroutine
    9874             : 
    9875             : #endif
    9876             : 
    9877             : #if RK1_ENABLED
    9878             :     module subroutine setReplacedCusComDefIns_D1_D0_D0_RK1(array, pattern, replacement, iseq)
    9879             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9880             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D0_RK1
    9881             : #endif
    9882             :         use pm_kind, only: RKC => RK1
    9883             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
    9884             :         real(RKC)               , intent(in)                    :: pattern
    9885             :         real(RKC)               , intent(in)                    :: replacement
    9886             :        !procedure(iseq_D0_D0_RK1)                               :: iseq
    9887             :         procedure(logical(LK))                                  :: iseq
    9888             :     end subroutine
    9889             : #endif
    9890             : 
    9891             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9892             : 
    9893             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9894             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9895             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9896             : 
    9897             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9898             : 
    9899             : #if SK5_ENABLED
    9900             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_SK5(array, pattern, replacement, iseq)
    9901             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9902             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_SK5
    9903             : #endif
    9904             :         use pm_kind, only: SKC => SK5
    9905             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9906             :         character(*,SKC)        , intent(in)                    :: pattern
    9907             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    9908             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
    9909             :         procedure(logical(LK))                                  :: iseq
    9910             :     end subroutine
    9911             : #endif
    9912             : 
    9913             : #if SK4_ENABLED
    9914             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_SK4(array, pattern, replacement, iseq)
    9915             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9916             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_SK4
    9917             : #endif
    9918             :         use pm_kind, only: SKC => SK4
    9919             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9920             :         character(*,SKC)        , intent(in)                    :: pattern
    9921             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    9922             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
    9923             :         procedure(logical(LK))                                  :: iseq
    9924             :     end subroutine
    9925             : #endif
    9926             : 
    9927             : #if SK3_ENABLED
    9928             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_SK3(array, pattern, replacement, iseq)
    9929             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9930             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_SK3
    9931             : #endif
    9932             :         use pm_kind, only: SKC => SK3
    9933             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9934             :         character(*,SKC)        , intent(in)                    :: pattern
    9935             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    9936             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
    9937             :         procedure(logical(LK))                                  :: iseq
    9938             :     end subroutine
    9939             : #endif
    9940             : 
    9941             : #if SK2_ENABLED
    9942             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_SK2(array, pattern, replacement, iseq)
    9943             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9944             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_SK2
    9945             : #endif
    9946             :         use pm_kind, only: SKC => SK2
    9947             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9948             :         character(*,SKC)        , intent(in)                    :: pattern
    9949             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    9950             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
    9951             :         procedure(logical(LK))                                  :: iseq
    9952             :     end subroutine
    9953             : 
    9954             : #endif
    9955             : 
    9956             : #if SK1_ENABLED
    9957             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_SK1(array, pattern, replacement, iseq)
    9958             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9959             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_SK1
    9960             : #endif
    9961             :         use pm_kind, only: SKC => SK1
    9962             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
    9963             :         character(*,SKC)        , intent(in)                    :: pattern
    9964             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
    9965             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
    9966             :         procedure(logical(LK))                                  :: iseq
    9967             :     end subroutine
    9968             : #endif
    9969             : 
    9970             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    9971             : 
    9972             : #if IK5_ENABLED
    9973             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_IK5(array, pattern, replacement, iseq)
    9974             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9975             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_IK5
    9976             : #endif
    9977             :         use pm_kind, only: IKC => IK5
    9978             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9979             :         integer(IKC)            , intent(in)                    :: pattern
    9980             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    9981             :        !procedure(iseq_D0_D0_IK5)                               :: iseq
    9982             :         procedure(logical(LK))                                  :: iseq
    9983             :     end subroutine
    9984             : #endif
    9985             : 
    9986             : #if IK4_ENABLED
    9987             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_IK4(array, pattern, replacement, iseq)
    9988             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
    9989             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_IK4
    9990             : #endif
    9991             :         use pm_kind, only: IKC => IK4
    9992             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
    9993             :         integer(IKC)            , intent(in)                    :: pattern
    9994             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
    9995             :        !procedure(iseq_D0_D0_IK4)                               :: iseq
    9996             :         procedure(logical(LK))                                  :: iseq
    9997             :     end subroutine
    9998             : #endif
    9999             : 
   10000             : #if IK3_ENABLED
   10001             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_IK3(array, pattern, replacement, iseq)
   10002             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10003             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_IK3
   10004             : #endif
   10005             :         use pm_kind, only: IKC => IK3
   10006             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10007             :         integer(IKC)            , intent(in)                    :: pattern
   10008             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   10009             :        !procedure(iseq_D0_D0_IK3)                               :: iseq
   10010             :         procedure(logical(LK))                                  :: iseq
   10011             :     end subroutine
   10012             : #endif
   10013             : 
   10014             : #if IK2_ENABLED
   10015             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_IK2(array, pattern, replacement, iseq)
   10016             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10017             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_IK2
   10018             : #endif
   10019             :         use pm_kind, only: IKC => IK2
   10020             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10021             :         integer(IKC)            , intent(in)                    :: pattern
   10022             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   10023             :        !procedure(iseq_D0_D0_IK2)                               :: iseq
   10024             :         procedure(logical(LK))                                  :: iseq
   10025             :     end subroutine
   10026             : 
   10027             : #endif
   10028             : 
   10029             : #if IK1_ENABLED
   10030             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_IK1(array, pattern, replacement, iseq)
   10031             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10032             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_IK1
   10033             : #endif
   10034             :         use pm_kind, only: IKC => IK1
   10035             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10036             :         integer(IKC)            , intent(in)                    :: pattern
   10037             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   10038             :        !procedure(iseq_D0_D0_IK1)                               :: iseq
   10039             :         procedure(logical(LK))                                  :: iseq
   10040             :     end subroutine
   10041             : #endif
   10042             : 
   10043             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10044             : 
   10045             : #if LK5_ENABLED
   10046             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_LK5(array, pattern, replacement, iseq)
   10047             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10048             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_LK5
   10049             : #endif
   10050             :         use pm_kind, only: LKC => LK5
   10051             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10052             :         logical(LKC)            , intent(in)                    :: pattern
   10053             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   10054             :        !procedure(iseq_D0_D0_LK5)                               :: iseq
   10055             :         procedure(logical(LK))                                  :: iseq
   10056             :     end subroutine
   10057             : #endif
   10058             : 
   10059             : #if LK4_ENABLED
   10060             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_LK4(array, pattern, replacement, iseq)
   10061             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10062             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_LK4
   10063             : #endif
   10064             :         use pm_kind, only: LKC => LK4
   10065             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10066             :         logical(LKC)            , intent(in)                    :: pattern
   10067             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   10068             :        !procedure(iseq_D0_D0_LK4)                               :: iseq
   10069             :         procedure(logical(LK))                                  :: iseq
   10070             :     end subroutine
   10071             : #endif
   10072             : 
   10073             : #if LK3_ENABLED
   10074             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_LK3(array, pattern, replacement, iseq)
   10075             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10076             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_LK3
   10077             : #endif
   10078             :         use pm_kind, only: LKC => LK3
   10079             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10080             :         logical(LKC)            , intent(in)                    :: pattern
   10081             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   10082             :        !procedure(iseq_D0_D0_LK3)                               :: iseq
   10083             :         procedure(logical(LK))                                  :: iseq
   10084             :     end subroutine
   10085             : #endif
   10086             : 
   10087             : #if LK2_ENABLED
   10088             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_LK2(array, pattern, replacement, iseq)
   10089             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10090             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_LK2
   10091             : #endif
   10092             :         use pm_kind, only: LKC => LK2
   10093             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10094             :         logical(LKC)            , intent(in)                    :: pattern
   10095             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   10096             :        !procedure(iseq_D0_D0_LK2)                               :: iseq
   10097             :         procedure(logical(LK))                                  :: iseq
   10098             :     end subroutine
   10099             : 
   10100             : #endif
   10101             : 
   10102             : #if LK1_ENABLED
   10103             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_LK1(array, pattern, replacement, iseq)
   10104             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10105             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_LK1
   10106             : #endif
   10107             :         use pm_kind, only: LKC => LK1
   10108             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10109             :         logical(LKC)            , intent(in)                    :: pattern
   10110             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   10111             :        !procedure(iseq_D0_D0_LK1)                               :: iseq
   10112             :         procedure(logical(LK))                                  :: iseq
   10113             :     end subroutine
   10114             : #endif
   10115             : 
   10116             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10117             : 
   10118             : #if CK5_ENABLED
   10119             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_CK5(array, pattern, replacement, iseq)
   10120             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10121             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_CK5
   10122             : #endif
   10123             :         use pm_kind, only: CKC => CK5
   10124             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10125             :         complex(CKC)            , intent(in)                    :: pattern
   10126             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   10127             :        !procedure(iseq_D0_D0_CK5)                               :: iseq
   10128             :         procedure(logical(LK))                                  :: iseq
   10129             :     end subroutine
   10130             : #endif
   10131             : 
   10132             : #if CK4_ENABLED
   10133             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_CK4(array, pattern, replacement, iseq)
   10134             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10135             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_CK4
   10136             : #endif
   10137             :         use pm_kind, only: CKC => CK4
   10138             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10139             :         complex(CKC)            , intent(in)                    :: pattern
   10140             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   10141             :        !procedure(iseq_D0_D0_CK4)                               :: iseq
   10142             :         procedure(logical(LK))                                  :: iseq
   10143             :     end subroutine
   10144             : #endif
   10145             : 
   10146             : #if CK3_ENABLED
   10147             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_CK3(array, pattern, replacement, iseq)
   10148             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10149             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_CK3
   10150             : #endif
   10151             :         use pm_kind, only: CKC => CK3
   10152             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10153             :         complex(CKC)            , intent(in)                    :: pattern
   10154             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   10155             :        !procedure(iseq_D0_D0_CK3)                               :: iseq
   10156             :         procedure(logical(LK))                                  :: iseq
   10157             :     end subroutine
   10158             : #endif
   10159             : 
   10160             : #if CK2_ENABLED
   10161             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_CK2(array, pattern, replacement, iseq)
   10162             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10163             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_CK2
   10164             : #endif
   10165             :         use pm_kind, only: CKC => CK2
   10166             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10167             :         complex(CKC)            , intent(in)                    :: pattern
   10168             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   10169             :        !procedure(iseq_D0_D0_CK2)                               :: iseq
   10170             :         procedure(logical(LK))                                  :: iseq
   10171             :     end subroutine
   10172             : 
   10173             : #endif
   10174             : 
   10175             : #if CK1_ENABLED
   10176             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_CK1(array, pattern, replacement, iseq)
   10177             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10178             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_CK1
   10179             : #endif
   10180             :         use pm_kind, only: CKC => CK1
   10181             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10182             :         complex(CKC)            , intent(in)                    :: pattern
   10183             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   10184             :        !procedure(iseq_D0_D0_CK1)                               :: iseq
   10185             :         procedure(logical(LK))                                  :: iseq
   10186             :     end subroutine
   10187             : #endif
   10188             : 
   10189             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10190             : 
   10191             : #if RK5_ENABLED
   10192             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_RK5(array, pattern, replacement, iseq)
   10193             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10194             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_RK5
   10195             : #endif
   10196             :         use pm_kind, only: RKC => RK5
   10197             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10198             :         real(RKC)               , intent(in)                    :: pattern
   10199             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   10200             :        !procedure(iseq_D0_D0_RK5)                               :: iseq
   10201             :         procedure(logical(LK))                                  :: iseq
   10202             :     end subroutine
   10203             : #endif
   10204             : 
   10205             : #if RK4_ENABLED
   10206             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_RK4(array, pattern, replacement, iseq)
   10207             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10208             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_RK4
   10209             : #endif
   10210             :         use pm_kind, only: RKC => RK4
   10211             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10212             :         real(RKC)               , intent(in)                    :: pattern
   10213             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   10214             :        !procedure(iseq_D0_D0_RK4)                               :: iseq
   10215             :         procedure(logical(LK))                                  :: iseq
   10216             :     end subroutine
   10217             : #endif
   10218             : 
   10219             : #if RK3_ENABLED
   10220             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_RK3(array, pattern, replacement, iseq)
   10221             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10222             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_RK3
   10223             : #endif
   10224             :         use pm_kind, only: RKC => RK3
   10225             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10226             :         real(RKC)               , intent(in)                    :: pattern
   10227             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   10228             :        !procedure(iseq_D0_D0_RK3)                               :: iseq
   10229             :         procedure(logical(LK))                                  :: iseq
   10230             :     end subroutine
   10231             : #endif
   10232             : 
   10233             : #if RK2_ENABLED
   10234             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_RK2(array, pattern, replacement, iseq)
   10235             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10236             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_RK2
   10237             : #endif
   10238             :         use pm_kind, only: RKC => RK2
   10239             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10240             :         real(RKC)               , intent(in)                    :: pattern
   10241             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   10242             :        !procedure(iseq_D0_D0_RK2)                               :: iseq
   10243             :         procedure(logical(LK))                                  :: iseq
   10244             :     end subroutine
   10245             : 
   10246             : #endif
   10247             : 
   10248             : #if RK1_ENABLED
   10249             :     module subroutine setReplacedCusComDefIns_D1_D0_D1_RK1(array, pattern, replacement, iseq)
   10250             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10251             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D0_D1_RK1
   10252             : #endif
   10253             :         use pm_kind, only: RKC => RK1
   10254             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10255             :         real(RKC)               , intent(in)                    :: pattern
   10256             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   10257             :        !procedure(iseq_D0_D0_RK1)                               :: iseq
   10258             :         procedure(logical(LK))                                  :: iseq
   10259             :     end subroutine
   10260             : #endif
   10261             : 
   10262             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10263             : 
   10264             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10265             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10266             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10267             : 
   10268             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10269             : 
   10270             : #if SK5_ENABLED
   10271             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_SK5(array, pattern, replacement, iseq)
   10272             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10273             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_SK5
   10274             : #endif
   10275             :         use pm_kind, only: SKC => SK5
   10276             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   10277             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   10278             :         character(*,SKC)        , intent(in)                    :: replacement
   10279             :        !procedure(iseq_D1_D1_SK5)                               :: iseq
   10280             :         procedure(logical(LK))                                  :: iseq
   10281             :     end subroutine
   10282             : #endif
   10283             : 
   10284             : #if SK4_ENABLED
   10285             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_SK4(array, pattern, replacement, iseq)
   10286             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10287             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_SK4
   10288             : #endif
   10289             :         use pm_kind, only: SKC => SK4
   10290             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   10291             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   10292             :         character(*,SKC)        , intent(in)                    :: replacement
   10293             :        !procedure(iseq_D1_D1_SK4)                               :: iseq
   10294             :         procedure(logical(LK))                                  :: iseq
   10295             :     end subroutine
   10296             : #endif
   10297             : 
   10298             : #if SK3_ENABLED
   10299             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_SK3(array, pattern, replacement, iseq)
   10300             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10301             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_SK3
   10302             : #endif
   10303             :         use pm_kind, only: SKC => SK3
   10304             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   10305             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   10306             :         character(*,SKC)        , intent(in)                    :: replacement
   10307             :        !procedure(iseq_D1_D1_SK3)                               :: iseq
   10308             :         procedure(logical(LK))                                  :: iseq
   10309             :     end subroutine
   10310             : #endif
   10311             : 
   10312             : #if SK2_ENABLED
   10313             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_SK2(array, pattern, replacement, iseq)
   10314             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10315             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_SK2
   10316             : #endif
   10317             :         use pm_kind, only: SKC => SK2
   10318             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   10319             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   10320             :         character(*,SKC)        , intent(in)                    :: replacement
   10321             :        !procedure(iseq_D1_D1_SK2)                               :: iseq
   10322             :         procedure(logical(LK))                                  :: iseq
   10323             :     end subroutine
   10324             : 
   10325             : #endif
   10326             : 
   10327             : #if SK1_ENABLED
   10328             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_SK1(array, pattern, replacement, iseq)
   10329             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10330             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_SK1
   10331             : #endif
   10332             :         use pm_kind, only: SKC => SK1
   10333             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   10334             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   10335             :         character(*,SKC)        , intent(in)                    :: replacement
   10336             :        !procedure(iseq_D1_D1_SK1)                               :: iseq
   10337             :         procedure(logical(LK))                                  :: iseq
   10338             :     end subroutine
   10339             : #endif
   10340             : 
   10341             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10342             : 
   10343             : #if IK5_ENABLED
   10344             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_IK5(array, pattern, replacement, iseq)
   10345             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10346             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_IK5
   10347             : #endif
   10348             :         use pm_kind, only: IKC => IK5
   10349             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10350             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   10351             :         integer(IKC)            , intent(in)                    :: replacement
   10352             :        !procedure(iseq_D1_D1_IK5)                               :: iseq
   10353             :         procedure(logical(LK))                                  :: iseq
   10354             :     end subroutine
   10355             : #endif
   10356             : 
   10357             : #if IK4_ENABLED
   10358             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_IK4(array, pattern, replacement, iseq)
   10359             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10360             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_IK4
   10361             : #endif
   10362             :         use pm_kind, only: IKC => IK4
   10363             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10364             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   10365             :         integer(IKC)            , intent(in)                    :: replacement
   10366             :        !procedure(iseq_D1_D1_IK4)                               :: iseq
   10367             :         procedure(logical(LK))                                  :: iseq
   10368             :     end subroutine
   10369             : #endif
   10370             : 
   10371             : #if IK3_ENABLED
   10372             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_IK3(array, pattern, replacement, iseq)
   10373             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10374             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_IK3
   10375             : #endif
   10376             :         use pm_kind, only: IKC => IK3
   10377             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10378             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   10379             :         integer(IKC)            , intent(in)                    :: replacement
   10380             :        !procedure(iseq_D1_D1_IK3)                               :: iseq
   10381             :         procedure(logical(LK))                                  :: iseq
   10382             :     end subroutine
   10383             : #endif
   10384             : 
   10385             : #if IK2_ENABLED
   10386             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_IK2(array, pattern, replacement, iseq)
   10387             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10388             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_IK2
   10389             : #endif
   10390             :         use pm_kind, only: IKC => IK2
   10391             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10392             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   10393             :         integer(IKC)            , intent(in)                    :: replacement
   10394             :        !procedure(iseq_D1_D1_IK2)                               :: iseq
   10395             :         procedure(logical(LK))                                  :: iseq
   10396             :     end subroutine
   10397             : 
   10398             : #endif
   10399             : 
   10400             : #if IK1_ENABLED
   10401             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_IK1(array, pattern, replacement, iseq)
   10402             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10403             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_IK1
   10404             : #endif
   10405             :         use pm_kind, only: IKC => IK1
   10406             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10407             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   10408             :         integer(IKC)            , intent(in)                    :: replacement
   10409             :        !procedure(iseq_D1_D1_IK1)                               :: iseq
   10410             :         procedure(logical(LK))                                  :: iseq
   10411             :     end subroutine
   10412             : #endif
   10413             : 
   10414             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10415             : 
   10416             : #if LK5_ENABLED
   10417             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_LK5(array, pattern, replacement, iseq)
   10418             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10419             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_LK5
   10420             : #endif
   10421             :         use pm_kind, only: LKC => LK5
   10422             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10423             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   10424             :         logical(LKC)            , intent(in)                    :: replacement
   10425             :        !procedure(iseq_D1_D1_LK5)                               :: iseq
   10426             :         procedure(logical(LK))                                  :: iseq
   10427             :     end subroutine
   10428             : #endif
   10429             : 
   10430             : #if LK4_ENABLED
   10431             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_LK4(array, pattern, replacement, iseq)
   10432             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10433             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_LK4
   10434             : #endif
   10435             :         use pm_kind, only: LKC => LK4
   10436             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10437             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   10438             :         logical(LKC)            , intent(in)                    :: replacement
   10439             :        !procedure(iseq_D1_D1_LK4)                               :: iseq
   10440             :         procedure(logical(LK))                                  :: iseq
   10441             :     end subroutine
   10442             : #endif
   10443             : 
   10444             : #if LK3_ENABLED
   10445             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_LK3(array, pattern, replacement, iseq)
   10446             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10447             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_LK3
   10448             : #endif
   10449             :         use pm_kind, only: LKC => LK3
   10450             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10451             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   10452             :         logical(LKC)            , intent(in)                    :: replacement
   10453             :        !procedure(iseq_D1_D1_LK3)                               :: iseq
   10454             :         procedure(logical(LK))                                  :: iseq
   10455             :     end subroutine
   10456             : #endif
   10457             : 
   10458             : #if LK2_ENABLED
   10459             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_LK2(array, pattern, replacement, iseq)
   10460             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10461             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_LK2
   10462             : #endif
   10463             :         use pm_kind, only: LKC => LK2
   10464             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10465             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   10466             :         logical(LKC)            , intent(in)                    :: replacement
   10467             :        !procedure(iseq_D1_D1_LK2)                               :: iseq
   10468             :         procedure(logical(LK))                                  :: iseq
   10469             :     end subroutine
   10470             : 
   10471             : #endif
   10472             : 
   10473             : #if LK1_ENABLED
   10474             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_LK1(array, pattern, replacement, iseq)
   10475             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10476             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_LK1
   10477             : #endif
   10478             :         use pm_kind, only: LKC => LK1
   10479             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10480             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   10481             :         logical(LKC)            , intent(in)                    :: replacement
   10482             :        !procedure(iseq_D1_D1_LK1)                               :: iseq
   10483             :         procedure(logical(LK))                                  :: iseq
   10484             :     end subroutine
   10485             : #endif
   10486             : 
   10487             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10488             : 
   10489             : #if CK5_ENABLED
   10490             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_CK5(array, pattern, replacement, iseq)
   10491             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10492             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_CK5
   10493             : #endif
   10494             :         use pm_kind, only: CKC => CK5
   10495             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10496             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   10497             :         complex(CKC)            , intent(in)                    :: replacement
   10498             :        !procedure(iseq_D1_D1_CK5)                               :: iseq
   10499             :         procedure(logical(LK))                                  :: iseq
   10500             :     end subroutine
   10501             : #endif
   10502             : 
   10503             : #if CK4_ENABLED
   10504             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_CK4(array, pattern, replacement, iseq)
   10505             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10506             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_CK4
   10507             : #endif
   10508             :         use pm_kind, only: CKC => CK4
   10509             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10510             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   10511             :         complex(CKC)            , intent(in)                    :: replacement
   10512             :        !procedure(iseq_D1_D1_CK4)                               :: iseq
   10513             :         procedure(logical(LK))                                  :: iseq
   10514             :     end subroutine
   10515             : #endif
   10516             : 
   10517             : #if CK3_ENABLED
   10518             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_CK3(array, pattern, replacement, iseq)
   10519             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10520             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_CK3
   10521             : #endif
   10522             :         use pm_kind, only: CKC => CK3
   10523             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10524             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   10525             :         complex(CKC)            , intent(in)                    :: replacement
   10526             :        !procedure(iseq_D1_D1_CK3)                               :: iseq
   10527             :         procedure(logical(LK))                                  :: iseq
   10528             :     end subroutine
   10529             : #endif
   10530             : 
   10531             : #if CK2_ENABLED
   10532             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_CK2(array, pattern, replacement, iseq)
   10533             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10534             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_CK2
   10535             : #endif
   10536             :         use pm_kind, only: CKC => CK2
   10537             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10538             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   10539             :         complex(CKC)            , intent(in)                    :: replacement
   10540             :        !procedure(iseq_D1_D1_CK2)                               :: iseq
   10541             :         procedure(logical(LK))                                  :: iseq
   10542             :     end subroutine
   10543             : 
   10544             : #endif
   10545             : 
   10546             : #if CK1_ENABLED
   10547             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_CK1(array, pattern, replacement, iseq)
   10548             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10549             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_CK1
   10550             : #endif
   10551             :         use pm_kind, only: CKC => CK1
   10552             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10553             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   10554             :         complex(CKC)            , intent(in)                    :: replacement
   10555             :        !procedure(iseq_D1_D1_CK1)                               :: iseq
   10556             :         procedure(logical(LK))                                  :: iseq
   10557             :     end subroutine
   10558             : #endif
   10559             : 
   10560             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10561             : 
   10562             : #if RK5_ENABLED
   10563             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_RK5(array, pattern, replacement, iseq)
   10564             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10565             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_RK5
   10566             : #endif
   10567             :         use pm_kind, only: RKC => RK5
   10568             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10569             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   10570             :         real(RKC)               , intent(in)                    :: replacement
   10571             :        !procedure(iseq_D1_D1_RK5)                               :: iseq
   10572             :         procedure(logical(LK))                                  :: iseq
   10573             :     end subroutine
   10574             : #endif
   10575             : 
   10576             : #if RK4_ENABLED
   10577             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_RK4(array, pattern, replacement, iseq)
   10578             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10579             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_RK4
   10580             : #endif
   10581             :         use pm_kind, only: RKC => RK4
   10582             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10583             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   10584             :         real(RKC)               , intent(in)                    :: replacement
   10585             :        !procedure(iseq_D1_D1_RK4)                               :: iseq
   10586             :         procedure(logical(LK))                                  :: iseq
   10587             :     end subroutine
   10588             : #endif
   10589             : 
   10590             : #if RK3_ENABLED
   10591             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_RK3(array, pattern, replacement, iseq)
   10592             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10593             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_RK3
   10594             : #endif
   10595             :         use pm_kind, only: RKC => RK3
   10596             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10597             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   10598             :         real(RKC)               , intent(in)                    :: replacement
   10599             :        !procedure(iseq_D1_D1_RK3)                               :: iseq
   10600             :         procedure(logical(LK))                                  :: iseq
   10601             :     end subroutine
   10602             : #endif
   10603             : 
   10604             : #if RK2_ENABLED
   10605             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_RK2(array, pattern, replacement, iseq)
   10606             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10607             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_RK2
   10608             : #endif
   10609             :         use pm_kind, only: RKC => RK2
   10610             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10611             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   10612             :         real(RKC)               , intent(in)                    :: replacement
   10613             :        !procedure(iseq_D1_D1_RK2)                               :: iseq
   10614             :         procedure(logical(LK))                                  :: iseq
   10615             :     end subroutine
   10616             : 
   10617             : #endif
   10618             : 
   10619             : #if RK1_ENABLED
   10620             :     module subroutine setReplacedCusComDefIns_D1_D1_D0_RK1(array, pattern, replacement, iseq)
   10621             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10622             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D0_RK1
   10623             : #endif
   10624             :         use pm_kind, only: RKC => RK1
   10625             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10626             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   10627             :         real(RKC)               , intent(in)                    :: replacement
   10628             :        !procedure(iseq_D1_D1_RK1)                               :: iseq
   10629             :         procedure(logical(LK))                                  :: iseq
   10630             :     end subroutine
   10631             : #endif
   10632             : 
   10633             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10634             : 
   10635             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10636             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10637             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10638             : 
   10639             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10640             : 
   10641             : #if SK5_ENABLED
   10642             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_SK5(array, pattern, replacement, iseq)
   10643             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10644             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_SK5
   10645             : #endif
   10646             :         use pm_kind, only: SKC => SK5
   10647             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   10648             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   10649             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   10650             :        !procedure(iseq_D1_D1_SK5)                               :: iseq
   10651             :         procedure(logical(LK))                                  :: iseq
   10652             :     end subroutine
   10653             : #endif
   10654             : 
   10655             : #if SK4_ENABLED
   10656             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_SK4(array, pattern, replacement, iseq)
   10657             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10658             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_SK4
   10659             : #endif
   10660             :         use pm_kind, only: SKC => SK4
   10661             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   10662             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   10663             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   10664             :        !procedure(iseq_D1_D1_SK4)                               :: iseq
   10665             :         procedure(logical(LK))                                  :: iseq
   10666             :     end subroutine
   10667             : #endif
   10668             : 
   10669             : #if SK3_ENABLED
   10670             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_SK3(array, pattern, replacement, iseq)
   10671             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10672             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_SK3
   10673             : #endif
   10674             :         use pm_kind, only: SKC => SK3
   10675             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   10676             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   10677             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   10678             :        !procedure(iseq_D1_D1_SK3)                               :: iseq
   10679             :         procedure(logical(LK))                                  :: iseq
   10680             :     end subroutine
   10681             : #endif
   10682             : 
   10683             : #if SK2_ENABLED
   10684             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_SK2(array, pattern, replacement, iseq)
   10685             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10686             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_SK2
   10687             : #endif
   10688             :         use pm_kind, only: SKC => SK2
   10689             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   10690             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   10691             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   10692             :        !procedure(iseq_D1_D1_SK2)                               :: iseq
   10693             :         procedure(logical(LK))                                  :: iseq
   10694             :     end subroutine
   10695             : 
   10696             : #endif
   10697             : 
   10698             : #if SK1_ENABLED
   10699             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_SK1(array, pattern, replacement, iseq)
   10700             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10701             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_SK1
   10702             : #endif
   10703             :         use pm_kind, only: SKC => SK1
   10704             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   10705             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   10706             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   10707             :        !procedure(iseq_D1_D1_SK1)                               :: iseq
   10708             :         procedure(logical(LK))                                  :: iseq
   10709             :     end subroutine
   10710             : #endif
   10711             : 
   10712             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10713             : 
   10714             : #if IK5_ENABLED
   10715             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_IK5(array, pattern, replacement, iseq)
   10716             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10717             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_IK5
   10718             : #endif
   10719             :         use pm_kind, only: IKC => IK5
   10720             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10721             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   10722             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   10723             :        !procedure(iseq_D1_D1_IK5)                               :: iseq
   10724             :         procedure(logical(LK))                                  :: iseq
   10725             :     end subroutine
   10726             : #endif
   10727             : 
   10728             : #if IK4_ENABLED
   10729             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_IK4(array, pattern, replacement, iseq)
   10730             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10731             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_IK4
   10732             : #endif
   10733             :         use pm_kind, only: IKC => IK4
   10734             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10735             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   10736             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   10737             :        !procedure(iseq_D1_D1_IK4)                               :: iseq
   10738             :         procedure(logical(LK))                                  :: iseq
   10739             :     end subroutine
   10740             : #endif
   10741             : 
   10742             : #if IK3_ENABLED
   10743             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_IK3(array, pattern, replacement, iseq)
   10744             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10745             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_IK3
   10746             : #endif
   10747             :         use pm_kind, only: IKC => IK3
   10748             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10749             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   10750             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   10751             :        !procedure(iseq_D1_D1_IK3)                               :: iseq
   10752             :         procedure(logical(LK))                                  :: iseq
   10753             :     end subroutine
   10754             : #endif
   10755             : 
   10756             : #if IK2_ENABLED
   10757             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_IK2(array, pattern, replacement, iseq)
   10758             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10759             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_IK2
   10760             : #endif
   10761             :         use pm_kind, only: IKC => IK2
   10762             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10763             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   10764             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   10765             :        !procedure(iseq_D1_D1_IK2)                               :: iseq
   10766             :         procedure(logical(LK))                                  :: iseq
   10767             :     end subroutine
   10768             : 
   10769             : #endif
   10770             : 
   10771             : #if IK1_ENABLED
   10772             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_IK1(array, pattern, replacement, iseq)
   10773             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10774             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_IK1
   10775             : #endif
   10776             :         use pm_kind, only: IKC => IK1
   10777             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   10778             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   10779             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   10780             :        !procedure(iseq_D1_D1_IK1)                               :: iseq
   10781             :         procedure(logical(LK))                                  :: iseq
   10782             :     end subroutine
   10783             : #endif
   10784             : 
   10785             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10786             : 
   10787             : #if LK5_ENABLED
   10788             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_LK5(array, pattern, replacement, iseq)
   10789             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10790             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_LK5
   10791             : #endif
   10792             :         use pm_kind, only: LKC => LK5
   10793             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10794             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   10795             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   10796             :        !procedure(iseq_D1_D1_LK5)                               :: iseq
   10797             :         procedure(logical(LK))                                  :: iseq
   10798             :     end subroutine
   10799             : #endif
   10800             : 
   10801             : #if LK4_ENABLED
   10802             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_LK4(array, pattern, replacement, iseq)
   10803             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10804             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_LK4
   10805             : #endif
   10806             :         use pm_kind, only: LKC => LK4
   10807             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10808             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   10809             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   10810             :        !procedure(iseq_D1_D1_LK4)                               :: iseq
   10811             :         procedure(logical(LK))                                  :: iseq
   10812             :     end subroutine
   10813             : #endif
   10814             : 
   10815             : #if LK3_ENABLED
   10816             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_LK3(array, pattern, replacement, iseq)
   10817             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10818             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_LK3
   10819             : #endif
   10820             :         use pm_kind, only: LKC => LK3
   10821             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10822             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   10823             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   10824             :        !procedure(iseq_D1_D1_LK3)                               :: iseq
   10825             :         procedure(logical(LK))                                  :: iseq
   10826             :     end subroutine
   10827             : #endif
   10828             : 
   10829             : #if LK2_ENABLED
   10830             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_LK2(array, pattern, replacement, iseq)
   10831             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10832             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_LK2
   10833             : #endif
   10834             :         use pm_kind, only: LKC => LK2
   10835             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10836             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   10837             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   10838             :        !procedure(iseq_D1_D1_LK2)                               :: iseq
   10839             :         procedure(logical(LK))                                  :: iseq
   10840             :     end subroutine
   10841             : 
   10842             : #endif
   10843             : 
   10844             : #if LK1_ENABLED
   10845             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_LK1(array, pattern, replacement, iseq)
   10846             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10847             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_LK1
   10848             : #endif
   10849             :         use pm_kind, only: LKC => LK1
   10850             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   10851             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   10852             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   10853             :        !procedure(iseq_D1_D1_LK1)                               :: iseq
   10854             :         procedure(logical(LK))                                  :: iseq
   10855             :     end subroutine
   10856             : #endif
   10857             : 
   10858             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10859             : 
   10860             : #if CK5_ENABLED
   10861             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_CK5(array, pattern, replacement, iseq)
   10862             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10863             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_CK5
   10864             : #endif
   10865             :         use pm_kind, only: CKC => CK5
   10866             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10867             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   10868             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   10869             :        !procedure(iseq_D1_D1_CK5)                               :: iseq
   10870             :         procedure(logical(LK))                                  :: iseq
   10871             :     end subroutine
   10872             : #endif
   10873             : 
   10874             : #if CK4_ENABLED
   10875             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_CK4(array, pattern, replacement, iseq)
   10876             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10877             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_CK4
   10878             : #endif
   10879             :         use pm_kind, only: CKC => CK4
   10880             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10881             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   10882             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   10883             :        !procedure(iseq_D1_D1_CK4)                               :: iseq
   10884             :         procedure(logical(LK))                                  :: iseq
   10885             :     end subroutine
   10886             : #endif
   10887             : 
   10888             : #if CK3_ENABLED
   10889             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_CK3(array, pattern, replacement, iseq)
   10890             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10891             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_CK3
   10892             : #endif
   10893             :         use pm_kind, only: CKC => CK3
   10894             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10895             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   10896             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   10897             :        !procedure(iseq_D1_D1_CK3)                               :: iseq
   10898             :         procedure(logical(LK))                                  :: iseq
   10899             :     end subroutine
   10900             : #endif
   10901             : 
   10902             : #if CK2_ENABLED
   10903             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_CK2(array, pattern, replacement, iseq)
   10904             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10905             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_CK2
   10906             : #endif
   10907             :         use pm_kind, only: CKC => CK2
   10908             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10909             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   10910             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   10911             :        !procedure(iseq_D1_D1_CK2)                               :: iseq
   10912             :         procedure(logical(LK))                                  :: iseq
   10913             :     end subroutine
   10914             : 
   10915             : #endif
   10916             : 
   10917             : #if CK1_ENABLED
   10918             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_CK1(array, pattern, replacement, iseq)
   10919             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10920             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_CK1
   10921             : #endif
   10922             :         use pm_kind, only: CKC => CK1
   10923             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   10924             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   10925             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   10926             :        !procedure(iseq_D1_D1_CK1)                               :: iseq
   10927             :         procedure(logical(LK))                                  :: iseq
   10928             :     end subroutine
   10929             : #endif
   10930             : 
   10931             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   10932             : 
   10933             : #if RK5_ENABLED
   10934             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_RK5(array, pattern, replacement, iseq)
   10935             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10936             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_RK5
   10937             : #endif
   10938             :         use pm_kind, only: RKC => RK5
   10939             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10940             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   10941             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   10942             :        !procedure(iseq_D1_D1_RK5)                               :: iseq
   10943             :         procedure(logical(LK))                                  :: iseq
   10944             :     end subroutine
   10945             : #endif
   10946             : 
   10947             : #if RK4_ENABLED
   10948             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_RK4(array, pattern, replacement, iseq)
   10949             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10950             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_RK4
   10951             : #endif
   10952             :         use pm_kind, only: RKC => RK4
   10953             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10954             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   10955             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   10956             :        !procedure(iseq_D1_D1_RK4)                               :: iseq
   10957             :         procedure(logical(LK))                                  :: iseq
   10958             :     end subroutine
   10959             : #endif
   10960             : 
   10961             : #if RK3_ENABLED
   10962             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_RK3(array, pattern, replacement, iseq)
   10963             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10964             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_RK3
   10965             : #endif
   10966             :         use pm_kind, only: RKC => RK3
   10967             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10968             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   10969             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   10970             :        !procedure(iseq_D1_D1_RK3)                               :: iseq
   10971             :         procedure(logical(LK))                                  :: iseq
   10972             :     end subroutine
   10973             : #endif
   10974             : 
   10975             : #if RK2_ENABLED
   10976             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_RK2(array, pattern, replacement, iseq)
   10977             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10978             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_RK2
   10979             : #endif
   10980             :         use pm_kind, only: RKC => RK2
   10981             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10982             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   10983             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   10984             :        !procedure(iseq_D1_D1_RK2)                               :: iseq
   10985             :         procedure(logical(LK))                                  :: iseq
   10986             :     end subroutine
   10987             : 
   10988             : #endif
   10989             : 
   10990             : #if RK1_ENABLED
   10991             :     module subroutine setReplacedCusComDefIns_D1_D1_D1_RK1(array, pattern, replacement, iseq)
   10992             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   10993             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComDefIns_D1_D1_D1_RK1
   10994             : #endif
   10995             :         use pm_kind, only: RKC => RK1
   10996             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   10997             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   10998             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   10999             :        !procedure(iseq_D1_D1_RK1)                               :: iseq
   11000             :         procedure(logical(LK))                                  :: iseq
   11001             :     end subroutine
   11002             : #endif
   11003             : 
   11004             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11005             : 
   11006             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11007             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11008             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11009             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11010             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11011             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11012             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11013             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11014             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11015             : 
   11016             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11017             : 
   11018             : #if SK5_ENABLED
   11019             :     PURE module subroutine setReplacedDefComCusIns_D0_D0_D0_SK5(array, pattern, replacement, instance, sorted, unique)
   11020             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11021             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D0_D0_D0_SK5
   11022             : #endif
   11023             :         use pm_kind, only: SKC => SK5
   11024             :         character(:,SKC)        , intent(inout) , allocatable   :: array
   11025             :         character(*,SKC)        , intent(in)                    :: pattern
   11026             :         character(*,SKC)        , intent(in)                    :: replacement
   11027             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11028             :         logical(LK)             , intent(in)    , optional      :: sorted
   11029             :         logical(LK)             , intent(in)    , optional      :: unique
   11030             :     end subroutine
   11031             : #endif
   11032             : 
   11033             : #if SK4_ENABLED
   11034             :     PURE module subroutine setReplacedDefComCusIns_D0_D0_D0_SK4(array, pattern, replacement, instance, sorted, unique)
   11035             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11036             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D0_D0_D0_SK4
   11037             : #endif
   11038             :         use pm_kind, only: SKC => SK4
   11039             :         character(:,SKC)        , intent(inout) , allocatable   :: array
   11040             :         character(*,SKC)        , intent(in)                    :: pattern
   11041             :         character(*,SKC)        , intent(in)                    :: replacement
   11042             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11043             :         logical(LK)             , intent(in)    , optional      :: sorted
   11044             :         logical(LK)             , intent(in)    , optional      :: unique
   11045             :     end subroutine
   11046             : #endif
   11047             : 
   11048             : #if SK3_ENABLED
   11049             :     PURE module subroutine setReplacedDefComCusIns_D0_D0_D0_SK3(array, pattern, replacement, instance, sorted, unique)
   11050             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11051             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D0_D0_D0_SK3
   11052             : #endif
   11053             :         use pm_kind, only: SKC => SK3
   11054             :         character(:,SKC)        , intent(inout) , allocatable   :: array
   11055             :         character(*,SKC)        , intent(in)                    :: pattern
   11056             :         character(*,SKC)        , intent(in)                    :: replacement
   11057             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11058             :         logical(LK)             , intent(in)    , optional      :: sorted
   11059             :         logical(LK)             , intent(in)    , optional      :: unique
   11060             :     end subroutine
   11061             : #endif
   11062             : 
   11063             : #if SK2_ENABLED
   11064             :     PURE module subroutine setReplacedDefComCusIns_D0_D0_D0_SK2(array, pattern, replacement, instance, sorted, unique)
   11065             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11066             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D0_D0_D0_SK2
   11067             : #endif
   11068             :         use pm_kind, only: SKC => SK2
   11069             :         character(:,SKC)        , intent(inout) , allocatable   :: array
   11070             :         character(*,SKC)        , intent(in)                    :: pattern
   11071             :         character(*,SKC)        , intent(in)                    :: replacement
   11072             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11073             :         logical(LK)             , intent(in)    , optional      :: sorted
   11074             :         logical(LK)             , intent(in)    , optional      :: unique
   11075             :     end subroutine
   11076             : 
   11077             : #endif
   11078             : 
   11079             : #if SK1_ENABLED
   11080             :     PURE module subroutine setReplacedDefComCusIns_D0_D0_D0_SK1(array, pattern, replacement, instance, sorted, unique)
   11081             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11082             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D0_D0_D0_SK1
   11083             : #endif
   11084             :         use pm_kind, only: SKC => SK1
   11085             :         character(:,SKC)        , intent(inout) , allocatable   :: array
   11086             :         character(*,SKC)        , intent(in)                    :: pattern
   11087             :         character(*,SKC)        , intent(in)                    :: replacement
   11088             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11089             :         logical(LK)             , intent(in)    , optional      :: sorted
   11090             :         logical(LK)             , intent(in)    , optional      :: unique
   11091             :     end subroutine
   11092             : #endif
   11093             : 
   11094             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11095             : 
   11096             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11097             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11098             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11099             : 
   11100             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11101             : 
   11102             : #if SK5_ENABLED
   11103             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_SK5(array, pattern, replacement, instance, sorted, unique)
   11104             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11105             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_SK5
   11106             : #endif
   11107             :         use pm_kind, only: SKC => SK5
   11108             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11109             :         character(*,SKC)        , intent(in)                    :: pattern
   11110             :         character(*,SKC)        , intent(in)                    :: replacement
   11111             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11112             :         logical(LK)             , intent(in)    , optional      :: sorted
   11113             :         logical(LK)             , intent(in)    , optional      :: unique
   11114             :     end subroutine
   11115             : #endif
   11116             : 
   11117             : #if SK4_ENABLED
   11118             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_SK4(array, pattern, replacement, instance, sorted, unique)
   11119             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11120             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_SK4
   11121             : #endif
   11122             :         use pm_kind, only: SKC => SK4
   11123             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11124             :         character(*,SKC)        , intent(in)                    :: pattern
   11125             :         character(*,SKC)        , intent(in)                    :: replacement
   11126             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11127             :         logical(LK)             , intent(in)    , optional      :: sorted
   11128             :         logical(LK)             , intent(in)    , optional      :: unique
   11129             :     end subroutine
   11130             : #endif
   11131             : 
   11132             : #if SK3_ENABLED
   11133             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_SK3(array, pattern, replacement, instance, sorted, unique)
   11134             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11135             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_SK3
   11136             : #endif
   11137             :         use pm_kind, only: SKC => SK3
   11138             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11139             :         character(*,SKC)        , intent(in)                    :: pattern
   11140             :         character(*,SKC)        , intent(in)                    :: replacement
   11141             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11142             :         logical(LK)             , intent(in)    , optional      :: sorted
   11143             :         logical(LK)             , intent(in)    , optional      :: unique
   11144             :     end subroutine
   11145             : #endif
   11146             : 
   11147             : #if SK2_ENABLED
   11148             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_SK2(array, pattern, replacement, instance, sorted, unique)
   11149             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11150             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_SK2
   11151             : #endif
   11152             :         use pm_kind, only: SKC => SK2
   11153             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11154             :         character(*,SKC)        , intent(in)                    :: pattern
   11155             :         character(*,SKC)        , intent(in)                    :: replacement
   11156             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11157             :         logical(LK)             , intent(in)    , optional      :: sorted
   11158             :         logical(LK)             , intent(in)    , optional      :: unique
   11159             :     end subroutine
   11160             : 
   11161             : #endif
   11162             : 
   11163             : #if SK1_ENABLED
   11164             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_SK1(array, pattern, replacement, instance, sorted, unique)
   11165             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11166             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_SK1
   11167             : #endif
   11168             :         use pm_kind, only: SKC => SK1
   11169             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11170             :         character(*,SKC)        , intent(in)                    :: pattern
   11171             :         character(*,SKC)        , intent(in)                    :: replacement
   11172             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11173             :         logical(LK)             , intent(in)    , optional      :: sorted
   11174             :         logical(LK)             , intent(in)    , optional      :: unique
   11175             :     end subroutine
   11176             : #endif
   11177             : 
   11178             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11179             : 
   11180             : #if IK5_ENABLED
   11181             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_IK5(array, pattern, replacement, instance, sorted, unique)
   11182             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11183             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_IK5
   11184             : #endif
   11185             :         use pm_kind, only: IKC => IK5
   11186             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11187             :         integer(IKC)            , intent(in)                    :: pattern
   11188             :         integer(IKC)            , intent(in)                    :: replacement
   11189             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11190             :         logical(LK)             , intent(in)    , optional      :: sorted
   11191             :         logical(LK)             , intent(in)    , optional      :: unique
   11192             :     end subroutine
   11193             : #endif
   11194             : 
   11195             : #if IK4_ENABLED
   11196             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_IK4(array, pattern, replacement, instance, sorted, unique)
   11197             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11198             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_IK4
   11199             : #endif
   11200             :         use pm_kind, only: IKC => IK4
   11201             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11202             :         integer(IKC)            , intent(in)                    :: pattern
   11203             :         integer(IKC)            , intent(in)                    :: replacement
   11204             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11205             :         logical(LK)             , intent(in)    , optional      :: sorted
   11206             :         logical(LK)             , intent(in)    , optional      :: unique
   11207             :     end subroutine
   11208             : #endif
   11209             : 
   11210             : #if IK3_ENABLED
   11211             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_IK3(array, pattern, replacement, instance, sorted, unique)
   11212             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11213             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_IK3
   11214             : #endif
   11215             :         use pm_kind, only: IKC => IK3
   11216             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11217             :         integer(IKC)            , intent(in)                    :: pattern
   11218             :         integer(IKC)            , intent(in)                    :: replacement
   11219             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11220             :         logical(LK)             , intent(in)    , optional      :: sorted
   11221             :         logical(LK)             , intent(in)    , optional      :: unique
   11222             :     end subroutine
   11223             : #endif
   11224             : 
   11225             : #if IK2_ENABLED
   11226             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_IK2(array, pattern, replacement, instance, sorted, unique)
   11227             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11228             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_IK2
   11229             : #endif
   11230             :         use pm_kind, only: IKC => IK2
   11231             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11232             :         integer(IKC)            , intent(in)                    :: pattern
   11233             :         integer(IKC)            , intent(in)                    :: replacement
   11234             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11235             :         logical(LK)             , intent(in)    , optional      :: sorted
   11236             :         logical(LK)             , intent(in)    , optional      :: unique
   11237             :     end subroutine
   11238             : 
   11239             : #endif
   11240             : 
   11241             : #if IK1_ENABLED
   11242             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_IK1(array, pattern, replacement, instance, sorted, unique)
   11243             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11244             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_IK1
   11245             : #endif
   11246             :         use pm_kind, only: IKC => IK1
   11247             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11248             :         integer(IKC)            , intent(in)                    :: pattern
   11249             :         integer(IKC)            , intent(in)                    :: replacement
   11250             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11251             :         logical(LK)             , intent(in)    , optional      :: sorted
   11252             :         logical(LK)             , intent(in)    , optional      :: unique
   11253             :     end subroutine
   11254             : #endif
   11255             : 
   11256             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11257             : 
   11258             : #if LK5_ENABLED
   11259             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_LK5(array, pattern, replacement, instance, sorted, unique)
   11260             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11261             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_LK5
   11262             : #endif
   11263             :         use pm_kind, only: LKC => LK5
   11264             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   11265             :         logical(LKC)            , intent(in)                    :: pattern
   11266             :         logical(LKC)            , intent(in)                    :: replacement
   11267             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11268             :         logical(LK)             , intent(in)    , optional      :: sorted
   11269             :         logical(LK)             , intent(in)    , optional      :: unique
   11270             :     end subroutine
   11271             : #endif
   11272             : 
   11273             : #if LK4_ENABLED
   11274             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_LK4(array, pattern, replacement, instance, sorted, unique)
   11275             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11276             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_LK4
   11277             : #endif
   11278             :         use pm_kind, only: LKC => LK4
   11279             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   11280             :         logical(LKC)            , intent(in)                    :: pattern
   11281             :         logical(LKC)            , intent(in)                    :: replacement
   11282             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11283             :         logical(LK)             , intent(in)    , optional      :: sorted
   11284             :         logical(LK)             , intent(in)    , optional      :: unique
   11285             :     end subroutine
   11286             : #endif
   11287             : 
   11288             : #if LK3_ENABLED
   11289             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_LK3(array, pattern, replacement, instance, sorted, unique)
   11290             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11291             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_LK3
   11292             : #endif
   11293             :         use pm_kind, only: LKC => LK3
   11294             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   11295             :         logical(LKC)            , intent(in)                    :: pattern
   11296             :         logical(LKC)            , intent(in)                    :: replacement
   11297             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11298             :         logical(LK)             , intent(in)    , optional      :: sorted
   11299             :         logical(LK)             , intent(in)    , optional      :: unique
   11300             :     end subroutine
   11301             : #endif
   11302             : 
   11303             : #if LK2_ENABLED
   11304             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_LK2(array, pattern, replacement, instance, sorted, unique)
   11305             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11306             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_LK2
   11307             : #endif
   11308             :         use pm_kind, only: LKC => LK2
   11309             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   11310             :         logical(LKC)            , intent(in)                    :: pattern
   11311             :         logical(LKC)            , intent(in)                    :: replacement
   11312             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11313             :         logical(LK)             , intent(in)    , optional      :: sorted
   11314             :         logical(LK)             , intent(in)    , optional      :: unique
   11315             :     end subroutine
   11316             : 
   11317             : #endif
   11318             : 
   11319             : #if LK1_ENABLED
   11320             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_LK1(array, pattern, replacement, instance, sorted, unique)
   11321             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11322             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_LK1
   11323             : #endif
   11324             :         use pm_kind, only: LKC => LK1
   11325             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   11326             :         logical(LKC)            , intent(in)                    :: pattern
   11327             :         logical(LKC)            , intent(in)                    :: replacement
   11328             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11329             :         logical(LK)             , intent(in)    , optional      :: sorted
   11330             :         logical(LK)             , intent(in)    , optional      :: unique
   11331             :     end subroutine
   11332             : #endif
   11333             : 
   11334             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11335             : 
   11336             : #if CK5_ENABLED
   11337             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_CK5(array, pattern, replacement, instance, sorted, unique)
   11338             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11339             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_CK5
   11340             : #endif
   11341             :         use pm_kind, only: CKC => CK5
   11342             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   11343             :         complex(CKC)            , intent(in)                    :: pattern
   11344             :         complex(CKC)            , intent(in)                    :: replacement
   11345             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11346             :         logical(LK)             , intent(in)    , optional      :: sorted
   11347             :         logical(LK)             , intent(in)    , optional      :: unique
   11348             :     end subroutine
   11349             : #endif
   11350             : 
   11351             : #if CK4_ENABLED
   11352             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_CK4(array, pattern, replacement, instance, sorted, unique)
   11353             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11354             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_CK4
   11355             : #endif
   11356             :         use pm_kind, only: CKC => CK4
   11357             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   11358             :         complex(CKC)            , intent(in)                    :: pattern
   11359             :         complex(CKC)            , intent(in)                    :: replacement
   11360             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11361             :         logical(LK)             , intent(in)    , optional      :: sorted
   11362             :         logical(LK)             , intent(in)    , optional      :: unique
   11363             :     end subroutine
   11364             : #endif
   11365             : 
   11366             : #if CK3_ENABLED
   11367             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_CK3(array, pattern, replacement, instance, sorted, unique)
   11368             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11369             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_CK3
   11370             : #endif
   11371             :         use pm_kind, only: CKC => CK3
   11372             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   11373             :         complex(CKC)            , intent(in)                    :: pattern
   11374             :         complex(CKC)            , intent(in)                    :: replacement
   11375             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11376             :         logical(LK)             , intent(in)    , optional      :: sorted
   11377             :         logical(LK)             , intent(in)    , optional      :: unique
   11378             :     end subroutine
   11379             : #endif
   11380             : 
   11381             : #if CK2_ENABLED
   11382             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_CK2(array, pattern, replacement, instance, sorted, unique)
   11383             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11384             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_CK2
   11385             : #endif
   11386             :         use pm_kind, only: CKC => CK2
   11387             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   11388             :         complex(CKC)            , intent(in)                    :: pattern
   11389             :         complex(CKC)            , intent(in)                    :: replacement
   11390             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11391             :         logical(LK)             , intent(in)    , optional      :: sorted
   11392             :         logical(LK)             , intent(in)    , optional      :: unique
   11393             :     end subroutine
   11394             : 
   11395             : #endif
   11396             : 
   11397             : #if CK1_ENABLED
   11398             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_CK1(array, pattern, replacement, instance, sorted, unique)
   11399             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11400             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_CK1
   11401             : #endif
   11402             :         use pm_kind, only: CKC => CK1
   11403             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   11404             :         complex(CKC)            , intent(in)                    :: pattern
   11405             :         complex(CKC)            , intent(in)                    :: replacement
   11406             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11407             :         logical(LK)             , intent(in)    , optional      :: sorted
   11408             :         logical(LK)             , intent(in)    , optional      :: unique
   11409             :     end subroutine
   11410             : #endif
   11411             : 
   11412             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11413             : 
   11414             : #if RK5_ENABLED
   11415             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_RK5(array, pattern, replacement, instance, sorted, unique)
   11416             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11417             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_RK5
   11418             : #endif
   11419             :         use pm_kind, only: RKC => RK5
   11420             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   11421             :         real(RKC)               , intent(in)                    :: pattern
   11422             :         real(RKC)               , intent(in)                    :: replacement
   11423             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11424             :         logical(LK)             , intent(in)    , optional      :: sorted
   11425             :         logical(LK)             , intent(in)    , optional      :: unique
   11426             :     end subroutine
   11427             : #endif
   11428             : 
   11429             : #if RK4_ENABLED
   11430             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_RK4(array, pattern, replacement, instance, sorted, unique)
   11431             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11432             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_RK4
   11433             : #endif
   11434             :         use pm_kind, only: RKC => RK4
   11435             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   11436             :         real(RKC)               , intent(in)                    :: pattern
   11437             :         real(RKC)               , intent(in)                    :: replacement
   11438             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11439             :         logical(LK)             , intent(in)    , optional      :: sorted
   11440             :         logical(LK)             , intent(in)    , optional      :: unique
   11441             :     end subroutine
   11442             : #endif
   11443             : 
   11444             : #if RK3_ENABLED
   11445             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_RK3(array, pattern, replacement, instance, sorted, unique)
   11446             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11447             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_RK3
   11448             : #endif
   11449             :         use pm_kind, only: RKC => RK3
   11450             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   11451             :         real(RKC)               , intent(in)                    :: pattern
   11452             :         real(RKC)               , intent(in)                    :: replacement
   11453             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11454             :         logical(LK)             , intent(in)    , optional      :: sorted
   11455             :         logical(LK)             , intent(in)    , optional      :: unique
   11456             :     end subroutine
   11457             : #endif
   11458             : 
   11459             : #if RK2_ENABLED
   11460             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_RK2(array, pattern, replacement, instance, sorted, unique)
   11461             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11462             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_RK2
   11463             : #endif
   11464             :         use pm_kind, only: RKC => RK2
   11465             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   11466             :         real(RKC)               , intent(in)                    :: pattern
   11467             :         real(RKC)               , intent(in)                    :: replacement
   11468             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11469             :         logical(LK)             , intent(in)    , optional      :: sorted
   11470             :         logical(LK)             , intent(in)    , optional      :: unique
   11471             :     end subroutine
   11472             : 
   11473             : #endif
   11474             : 
   11475             : #if RK1_ENABLED
   11476             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D0_RK1(array, pattern, replacement, instance, sorted, unique)
   11477             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11478             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D0_RK1
   11479             : #endif
   11480             :         use pm_kind, only: RKC => RK1
   11481             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   11482             :         real(RKC)               , intent(in)                    :: pattern
   11483             :         real(RKC)               , intent(in)                    :: replacement
   11484             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11485             :         logical(LK)             , intent(in)    , optional      :: sorted
   11486             :         logical(LK)             , intent(in)    , optional      :: unique
   11487             :     end subroutine
   11488             : #endif
   11489             : 
   11490             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11491             : 
   11492             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11493             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11494             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11495             : 
   11496             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11497             : 
   11498             : #if SK5_ENABLED
   11499             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_SK5(array, pattern, replacement, instance, sorted, unique)
   11500             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11501             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_SK5
   11502             : #endif
   11503             :         use pm_kind, only: SKC => SK5
   11504             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11505             :         character(*,SKC)        , intent(in)                    :: pattern
   11506             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   11507             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11508             :         logical(LK)             , intent(in)    , optional      :: sorted
   11509             :         logical(LK)             , intent(in)    , optional      :: unique
   11510             :     end subroutine
   11511             : #endif
   11512             : 
   11513             : #if SK4_ENABLED
   11514             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_SK4(array, pattern, replacement, instance, sorted, unique)
   11515             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11516             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_SK4
   11517             : #endif
   11518             :         use pm_kind, only: SKC => SK4
   11519             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11520             :         character(*,SKC)        , intent(in)                    :: pattern
   11521             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   11522             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11523             :         logical(LK)             , intent(in)    , optional      :: sorted
   11524             :         logical(LK)             , intent(in)    , optional      :: unique
   11525             :     end subroutine
   11526             : #endif
   11527             : 
   11528             : #if SK3_ENABLED
   11529             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_SK3(array, pattern, replacement, instance, sorted, unique)
   11530             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11531             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_SK3
   11532             : #endif
   11533             :         use pm_kind, only: SKC => SK3
   11534             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11535             :         character(*,SKC)        , intent(in)                    :: pattern
   11536             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   11537             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11538             :         logical(LK)             , intent(in)    , optional      :: sorted
   11539             :         logical(LK)             , intent(in)    , optional      :: unique
   11540             :     end subroutine
   11541             : #endif
   11542             : 
   11543             : #if SK2_ENABLED
   11544             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_SK2(array, pattern, replacement, instance, sorted, unique)
   11545             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11546             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_SK2
   11547             : #endif
   11548             :         use pm_kind, only: SKC => SK2
   11549             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11550             :         character(*,SKC)        , intent(in)                    :: pattern
   11551             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   11552             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11553             :         logical(LK)             , intent(in)    , optional      :: sorted
   11554             :         logical(LK)             , intent(in)    , optional      :: unique
   11555             :     end subroutine
   11556             : 
   11557             : #endif
   11558             : 
   11559             : #if SK1_ENABLED
   11560             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_SK1(array, pattern, replacement, instance, sorted, unique)
   11561             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11562             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_SK1
   11563             : #endif
   11564             :         use pm_kind, only: SKC => SK1
   11565             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11566             :         character(*,SKC)        , intent(in)                    :: pattern
   11567             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   11568             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11569             :         logical(LK)             , intent(in)    , optional      :: sorted
   11570             :         logical(LK)             , intent(in)    , optional      :: unique
   11571             :     end subroutine
   11572             : #endif
   11573             : 
   11574             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11575             : 
   11576             : #if IK5_ENABLED
   11577             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_IK5(array, pattern, replacement, instance, sorted, unique)
   11578             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11579             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_IK5
   11580             : #endif
   11581             :         use pm_kind, only: IKC => IK5
   11582             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11583             :         integer(IKC)            , intent(in)                    :: pattern
   11584             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   11585             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11586             :         logical(LK)             , intent(in)    , optional      :: sorted
   11587             :         logical(LK)             , intent(in)    , optional      :: unique
   11588             :     end subroutine
   11589             : #endif
   11590             : 
   11591             : #if IK4_ENABLED
   11592             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_IK4(array, pattern, replacement, instance, sorted, unique)
   11593             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11594             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_IK4
   11595             : #endif
   11596             :         use pm_kind, only: IKC => IK4
   11597             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11598             :         integer(IKC)            , intent(in)                    :: pattern
   11599             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   11600             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11601             :         logical(LK)             , intent(in)    , optional      :: sorted
   11602             :         logical(LK)             , intent(in)    , optional      :: unique
   11603             :     end subroutine
   11604             : #endif
   11605             : 
   11606             : #if IK3_ENABLED
   11607             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_IK3(array, pattern, replacement, instance, sorted, unique)
   11608             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11609             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_IK3
   11610             : #endif
   11611             :         use pm_kind, only: IKC => IK3
   11612             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11613             :         integer(IKC)            , intent(in)                    :: pattern
   11614             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   11615             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11616             :         logical(LK)             , intent(in)    , optional      :: sorted
   11617             :         logical(LK)             , intent(in)    , optional      :: unique
   11618             :     end subroutine
   11619             : #endif
   11620             : 
   11621             : #if IK2_ENABLED
   11622             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_IK2(array, pattern, replacement, instance, sorted, unique)
   11623             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11624             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_IK2
   11625             : #endif
   11626             :         use pm_kind, only: IKC => IK2
   11627             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11628             :         integer(IKC)            , intent(in)                    :: pattern
   11629             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   11630             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11631             :         logical(LK)             , intent(in)    , optional      :: sorted
   11632             :         logical(LK)             , intent(in)    , optional      :: unique
   11633             :     end subroutine
   11634             : 
   11635             : #endif
   11636             : 
   11637             : #if IK1_ENABLED
   11638             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_IK1(array, pattern, replacement, instance, sorted, unique)
   11639             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11640             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_IK1
   11641             : #endif
   11642             :         use pm_kind, only: IKC => IK1
   11643             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11644             :         integer(IKC)            , intent(in)                    :: pattern
   11645             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   11646             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11647             :         logical(LK)             , intent(in)    , optional      :: sorted
   11648             :         logical(LK)             , intent(in)    , optional      :: unique
   11649             :     end subroutine
   11650             : #endif
   11651             : 
   11652             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11653             : 
   11654             : #if LK5_ENABLED
   11655             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_LK5(array, pattern, replacement, instance, sorted, unique)
   11656             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11657             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_LK5
   11658             : #endif
   11659             :         use pm_kind, only: LKC => LK5
   11660             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   11661             :         logical(LKC)            , intent(in)                    :: pattern
   11662             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   11663             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11664             :         logical(LK)             , intent(in)    , optional      :: sorted
   11665             :         logical(LK)             , intent(in)    , optional      :: unique
   11666             :     end subroutine
   11667             : #endif
   11668             : 
   11669             : #if LK4_ENABLED
   11670             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_LK4(array, pattern, replacement, instance, sorted, unique)
   11671             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11672             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_LK4
   11673             : #endif
   11674             :         use pm_kind, only: LKC => LK4
   11675             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   11676             :         logical(LKC)            , intent(in)                    :: pattern
   11677             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   11678             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11679             :         logical(LK)             , intent(in)    , optional      :: sorted
   11680             :         logical(LK)             , intent(in)    , optional      :: unique
   11681             :     end subroutine
   11682             : #endif
   11683             : 
   11684             : #if LK3_ENABLED
   11685             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_LK3(array, pattern, replacement, instance, sorted, unique)
   11686             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11687             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_LK3
   11688             : #endif
   11689             :         use pm_kind, only: LKC => LK3
   11690             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   11691             :         logical(LKC)            , intent(in)                    :: pattern
   11692             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   11693             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11694             :         logical(LK)             , intent(in)    , optional      :: sorted
   11695             :         logical(LK)             , intent(in)    , optional      :: unique
   11696             :     end subroutine
   11697             : #endif
   11698             : 
   11699             : #if LK2_ENABLED
   11700             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_LK2(array, pattern, replacement, instance, sorted, unique)
   11701             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11702             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_LK2
   11703             : #endif
   11704             :         use pm_kind, only: LKC => LK2
   11705             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   11706             :         logical(LKC)            , intent(in)                    :: pattern
   11707             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   11708             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11709             :         logical(LK)             , intent(in)    , optional      :: sorted
   11710             :         logical(LK)             , intent(in)    , optional      :: unique
   11711             :     end subroutine
   11712             : 
   11713             : #endif
   11714             : 
   11715             : #if LK1_ENABLED
   11716             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_LK1(array, pattern, replacement, instance, sorted, unique)
   11717             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11718             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_LK1
   11719             : #endif
   11720             :         use pm_kind, only: LKC => LK1
   11721             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   11722             :         logical(LKC)            , intent(in)                    :: pattern
   11723             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   11724             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11725             :         logical(LK)             , intent(in)    , optional      :: sorted
   11726             :         logical(LK)             , intent(in)    , optional      :: unique
   11727             :     end subroutine
   11728             : #endif
   11729             : 
   11730             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11731             : 
   11732             : #if CK5_ENABLED
   11733             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_CK5(array, pattern, replacement, instance, sorted, unique)
   11734             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11735             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_CK5
   11736             : #endif
   11737             :         use pm_kind, only: CKC => CK5
   11738             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   11739             :         complex(CKC)            , intent(in)                    :: pattern
   11740             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   11741             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11742             :         logical(LK)             , intent(in)    , optional      :: sorted
   11743             :         logical(LK)             , intent(in)    , optional      :: unique
   11744             :     end subroutine
   11745             : #endif
   11746             : 
   11747             : #if CK4_ENABLED
   11748             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_CK4(array, pattern, replacement, instance, sorted, unique)
   11749             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11750             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_CK4
   11751             : #endif
   11752             :         use pm_kind, only: CKC => CK4
   11753             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   11754             :         complex(CKC)            , intent(in)                    :: pattern
   11755             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   11756             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11757             :         logical(LK)             , intent(in)    , optional      :: sorted
   11758             :         logical(LK)             , intent(in)    , optional      :: unique
   11759             :     end subroutine
   11760             : #endif
   11761             : 
   11762             : #if CK3_ENABLED
   11763             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_CK3(array, pattern, replacement, instance, sorted, unique)
   11764             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11765             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_CK3
   11766             : #endif
   11767             :         use pm_kind, only: CKC => CK3
   11768             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   11769             :         complex(CKC)            , intent(in)                    :: pattern
   11770             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   11771             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11772             :         logical(LK)             , intent(in)    , optional      :: sorted
   11773             :         logical(LK)             , intent(in)    , optional      :: unique
   11774             :     end subroutine
   11775             : #endif
   11776             : 
   11777             : #if CK2_ENABLED
   11778             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_CK2(array, pattern, replacement, instance, sorted, unique)
   11779             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11780             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_CK2
   11781             : #endif
   11782             :         use pm_kind, only: CKC => CK2
   11783             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   11784             :         complex(CKC)            , intent(in)                    :: pattern
   11785             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   11786             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11787             :         logical(LK)             , intent(in)    , optional      :: sorted
   11788             :         logical(LK)             , intent(in)    , optional      :: unique
   11789             :     end subroutine
   11790             : 
   11791             : #endif
   11792             : 
   11793             : #if CK1_ENABLED
   11794             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_CK1(array, pattern, replacement, instance, sorted, unique)
   11795             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11796             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_CK1
   11797             : #endif
   11798             :         use pm_kind, only: CKC => CK1
   11799             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   11800             :         complex(CKC)            , intent(in)                    :: pattern
   11801             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   11802             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11803             :         logical(LK)             , intent(in)    , optional      :: sorted
   11804             :         logical(LK)             , intent(in)    , optional      :: unique
   11805             :     end subroutine
   11806             : #endif
   11807             : 
   11808             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11809             : 
   11810             : #if RK5_ENABLED
   11811             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_RK5(array, pattern, replacement, instance, sorted, unique)
   11812             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11813             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_RK5
   11814             : #endif
   11815             :         use pm_kind, only: RKC => RK5
   11816             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   11817             :         real(RKC)               , intent(in)                    :: pattern
   11818             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   11819             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11820             :         logical(LK)             , intent(in)    , optional      :: sorted
   11821             :         logical(LK)             , intent(in)    , optional      :: unique
   11822             :     end subroutine
   11823             : #endif
   11824             : 
   11825             : #if RK4_ENABLED
   11826             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_RK4(array, pattern, replacement, instance, sorted, unique)
   11827             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11828             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_RK4
   11829             : #endif
   11830             :         use pm_kind, only: RKC => RK4
   11831             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   11832             :         real(RKC)               , intent(in)                    :: pattern
   11833             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   11834             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11835             :         logical(LK)             , intent(in)    , optional      :: sorted
   11836             :         logical(LK)             , intent(in)    , optional      :: unique
   11837             :     end subroutine
   11838             : #endif
   11839             : 
   11840             : #if RK3_ENABLED
   11841             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_RK3(array, pattern, replacement, instance, sorted, unique)
   11842             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11843             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_RK3
   11844             : #endif
   11845             :         use pm_kind, only: RKC => RK3
   11846             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   11847             :         real(RKC)               , intent(in)                    :: pattern
   11848             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   11849             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11850             :         logical(LK)             , intent(in)    , optional      :: sorted
   11851             :         logical(LK)             , intent(in)    , optional      :: unique
   11852             :     end subroutine
   11853             : #endif
   11854             : 
   11855             : #if RK2_ENABLED
   11856             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_RK2(array, pattern, replacement, instance, sorted, unique)
   11857             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11858             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_RK2
   11859             : #endif
   11860             :         use pm_kind, only: RKC => RK2
   11861             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   11862             :         real(RKC)               , intent(in)                    :: pattern
   11863             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   11864             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11865             :         logical(LK)             , intent(in)    , optional      :: sorted
   11866             :         logical(LK)             , intent(in)    , optional      :: unique
   11867             :     end subroutine
   11868             : 
   11869             : #endif
   11870             : 
   11871             : #if RK1_ENABLED
   11872             :     PURE module subroutine setReplacedDefComCusIns_D1_D0_D1_RK1(array, pattern, replacement, instance, sorted, unique)
   11873             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11874             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D0_D1_RK1
   11875             : #endif
   11876             :         use pm_kind, only: RKC => RK1
   11877             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   11878             :         real(RKC)               , intent(in)                    :: pattern
   11879             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   11880             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11881             :         logical(LK)             , intent(in)    , optional      :: sorted
   11882             :         logical(LK)             , intent(in)    , optional      :: unique
   11883             :     end subroutine
   11884             : #endif
   11885             : 
   11886             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11887             : 
   11888             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11889             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11890             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11891             : 
   11892             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11893             : 
   11894             : #if SK5_ENABLED
   11895             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_SK5(array, pattern, replacement, instance, sorted, unique)
   11896             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11897             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_SK5
   11898             : #endif
   11899             :         use pm_kind, only: SKC => SK5
   11900             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11901             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   11902             :         character(*,SKC)        , intent(in)                    :: replacement
   11903             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11904             :         logical(LK)             , intent(in)    , optional      :: sorted
   11905             :         logical(LK)             , intent(in)    , optional      :: unique
   11906             :     end subroutine
   11907             : #endif
   11908             : 
   11909             : #if SK4_ENABLED
   11910             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_SK4(array, pattern, replacement, instance, sorted, unique)
   11911             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11912             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_SK4
   11913             : #endif
   11914             :         use pm_kind, only: SKC => SK4
   11915             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11916             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   11917             :         character(*,SKC)        , intent(in)                    :: replacement
   11918             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11919             :         logical(LK)             , intent(in)    , optional      :: sorted
   11920             :         logical(LK)             , intent(in)    , optional      :: unique
   11921             :     end subroutine
   11922             : #endif
   11923             : 
   11924             : #if SK3_ENABLED
   11925             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_SK3(array, pattern, replacement, instance, sorted, unique)
   11926             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11927             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_SK3
   11928             : #endif
   11929             :         use pm_kind, only: SKC => SK3
   11930             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11931             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   11932             :         character(*,SKC)        , intent(in)                    :: replacement
   11933             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11934             :         logical(LK)             , intent(in)    , optional      :: sorted
   11935             :         logical(LK)             , intent(in)    , optional      :: unique
   11936             :     end subroutine
   11937             : #endif
   11938             : 
   11939             : #if SK2_ENABLED
   11940             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_SK2(array, pattern, replacement, instance, sorted, unique)
   11941             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11942             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_SK2
   11943             : #endif
   11944             :         use pm_kind, only: SKC => SK2
   11945             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11946             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   11947             :         character(*,SKC)        , intent(in)                    :: replacement
   11948             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11949             :         logical(LK)             , intent(in)    , optional      :: sorted
   11950             :         logical(LK)             , intent(in)    , optional      :: unique
   11951             :     end subroutine
   11952             : 
   11953             : #endif
   11954             : 
   11955             : #if SK1_ENABLED
   11956             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_SK1(array, pattern, replacement, instance, sorted, unique)
   11957             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11958             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_SK1
   11959             : #endif
   11960             :         use pm_kind, only: SKC => SK1
   11961             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   11962             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   11963             :         character(*,SKC)        , intent(in)                    :: replacement
   11964             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11965             :         logical(LK)             , intent(in)    , optional      :: sorted
   11966             :         logical(LK)             , intent(in)    , optional      :: unique
   11967             :     end subroutine
   11968             : #endif
   11969             : 
   11970             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   11971             : 
   11972             : #if IK5_ENABLED
   11973             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_IK5(array, pattern, replacement, instance, sorted, unique)
   11974             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11975             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_IK5
   11976             : #endif
   11977             :         use pm_kind, only: IKC => IK5
   11978             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11979             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   11980             :         integer(IKC)            , intent(in)                    :: replacement
   11981             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11982             :         logical(LK)             , intent(in)    , optional      :: sorted
   11983             :         logical(LK)             , intent(in)    , optional      :: unique
   11984             :     end subroutine
   11985             : #endif
   11986             : 
   11987             : #if IK4_ENABLED
   11988             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_IK4(array, pattern, replacement, instance, sorted, unique)
   11989             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   11990             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_IK4
   11991             : #endif
   11992             :         use pm_kind, only: IKC => IK4
   11993             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   11994             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   11995             :         integer(IKC)            , intent(in)                    :: replacement
   11996             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   11997             :         logical(LK)             , intent(in)    , optional      :: sorted
   11998             :         logical(LK)             , intent(in)    , optional      :: unique
   11999             :     end subroutine
   12000             : #endif
   12001             : 
   12002             : #if IK3_ENABLED
   12003             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_IK3(array, pattern, replacement, instance, sorted, unique)
   12004             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12005             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_IK3
   12006             : #endif
   12007             :         use pm_kind, only: IKC => IK3
   12008             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12009             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   12010             :         integer(IKC)            , intent(in)                    :: replacement
   12011             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12012             :         logical(LK)             , intent(in)    , optional      :: sorted
   12013             :         logical(LK)             , intent(in)    , optional      :: unique
   12014             :     end subroutine
   12015             : #endif
   12016             : 
   12017             : #if IK2_ENABLED
   12018             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_IK2(array, pattern, replacement, instance, sorted, unique)
   12019             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12020             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_IK2
   12021             : #endif
   12022             :         use pm_kind, only: IKC => IK2
   12023             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12024             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   12025             :         integer(IKC)            , intent(in)                    :: replacement
   12026             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12027             :         logical(LK)             , intent(in)    , optional      :: sorted
   12028             :         logical(LK)             , intent(in)    , optional      :: unique
   12029             :     end subroutine
   12030             : 
   12031             : #endif
   12032             : 
   12033             : #if IK1_ENABLED
   12034             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_IK1(array, pattern, replacement, instance, sorted, unique)
   12035             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12036             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_IK1
   12037             : #endif
   12038             :         use pm_kind, only: IKC => IK1
   12039             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12040             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   12041             :         integer(IKC)            , intent(in)                    :: replacement
   12042             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12043             :         logical(LK)             , intent(in)    , optional      :: sorted
   12044             :         logical(LK)             , intent(in)    , optional      :: unique
   12045             :     end subroutine
   12046             : #endif
   12047             : 
   12048             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12049             : 
   12050             : #if LK5_ENABLED
   12051             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_LK5(array, pattern, replacement, instance, sorted, unique)
   12052             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12053             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_LK5
   12054             : #endif
   12055             :         use pm_kind, only: LKC => LK5
   12056             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12057             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   12058             :         logical(LKC)            , intent(in)                    :: replacement
   12059             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12060             :         logical(LK)             , intent(in)    , optional      :: sorted
   12061             :         logical(LK)             , intent(in)    , optional      :: unique
   12062             :     end subroutine
   12063             : #endif
   12064             : 
   12065             : #if LK4_ENABLED
   12066             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_LK4(array, pattern, replacement, instance, sorted, unique)
   12067             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12068             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_LK4
   12069             : #endif
   12070             :         use pm_kind, only: LKC => LK4
   12071             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12072             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   12073             :         logical(LKC)            , intent(in)                    :: replacement
   12074             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12075             :         logical(LK)             , intent(in)    , optional      :: sorted
   12076             :         logical(LK)             , intent(in)    , optional      :: unique
   12077             :     end subroutine
   12078             : #endif
   12079             : 
   12080             : #if LK3_ENABLED
   12081             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_LK3(array, pattern, replacement, instance, sorted, unique)
   12082             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12083             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_LK3
   12084             : #endif
   12085             :         use pm_kind, only: LKC => LK3
   12086             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12087             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   12088             :         logical(LKC)            , intent(in)                    :: replacement
   12089             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12090             :         logical(LK)             , intent(in)    , optional      :: sorted
   12091             :         logical(LK)             , intent(in)    , optional      :: unique
   12092             :     end subroutine
   12093             : #endif
   12094             : 
   12095             : #if LK2_ENABLED
   12096             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_LK2(array, pattern, replacement, instance, sorted, unique)
   12097             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12098             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_LK2
   12099             : #endif
   12100             :         use pm_kind, only: LKC => LK2
   12101             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12102             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   12103             :         logical(LKC)            , intent(in)                    :: replacement
   12104             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12105             :         logical(LK)             , intent(in)    , optional      :: sorted
   12106             :         logical(LK)             , intent(in)    , optional      :: unique
   12107             :     end subroutine
   12108             : 
   12109             : #endif
   12110             : 
   12111             : #if LK1_ENABLED
   12112             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_LK1(array, pattern, replacement, instance, sorted, unique)
   12113             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12114             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_LK1
   12115             : #endif
   12116             :         use pm_kind, only: LKC => LK1
   12117             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12118             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   12119             :         logical(LKC)            , intent(in)                    :: replacement
   12120             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12121             :         logical(LK)             , intent(in)    , optional      :: sorted
   12122             :         logical(LK)             , intent(in)    , optional      :: unique
   12123             :     end subroutine
   12124             : #endif
   12125             : 
   12126             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12127             : 
   12128             : #if CK5_ENABLED
   12129             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_CK5(array, pattern, replacement, instance, sorted, unique)
   12130             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12131             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_CK5
   12132             : #endif
   12133             :         use pm_kind, only: CKC => CK5
   12134             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   12135             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   12136             :         complex(CKC)            , intent(in)                    :: replacement
   12137             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12138             :         logical(LK)             , intent(in)    , optional      :: sorted
   12139             :         logical(LK)             , intent(in)    , optional      :: unique
   12140             :     end subroutine
   12141             : #endif
   12142             : 
   12143             : #if CK4_ENABLED
   12144             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_CK4(array, pattern, replacement, instance, sorted, unique)
   12145             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12146             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_CK4
   12147             : #endif
   12148             :         use pm_kind, only: CKC => CK4
   12149             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   12150             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   12151             :         complex(CKC)            , intent(in)                    :: replacement
   12152             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12153             :         logical(LK)             , intent(in)    , optional      :: sorted
   12154             :         logical(LK)             , intent(in)    , optional      :: unique
   12155             :     end subroutine
   12156             : #endif
   12157             : 
   12158             : #if CK3_ENABLED
   12159             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_CK3(array, pattern, replacement, instance, sorted, unique)
   12160             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12161             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_CK3
   12162             : #endif
   12163             :         use pm_kind, only: CKC => CK3
   12164             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   12165             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   12166             :         complex(CKC)            , intent(in)                    :: replacement
   12167             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12168             :         logical(LK)             , intent(in)    , optional      :: sorted
   12169             :         logical(LK)             , intent(in)    , optional      :: unique
   12170             :     end subroutine
   12171             : #endif
   12172             : 
   12173             : #if CK2_ENABLED
   12174             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_CK2(array, pattern, replacement, instance, sorted, unique)
   12175             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12176             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_CK2
   12177             : #endif
   12178             :         use pm_kind, only: CKC => CK2
   12179             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   12180             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   12181             :         complex(CKC)            , intent(in)                    :: replacement
   12182             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12183             :         logical(LK)             , intent(in)    , optional      :: sorted
   12184             :         logical(LK)             , intent(in)    , optional      :: unique
   12185             :     end subroutine
   12186             : 
   12187             : #endif
   12188             : 
   12189             : #if CK1_ENABLED
   12190             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_CK1(array, pattern, replacement, instance, sorted, unique)
   12191             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12192             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_CK1
   12193             : #endif
   12194             :         use pm_kind, only: CKC => CK1
   12195             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   12196             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   12197             :         complex(CKC)            , intent(in)                    :: replacement
   12198             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12199             :         logical(LK)             , intent(in)    , optional      :: sorted
   12200             :         logical(LK)             , intent(in)    , optional      :: unique
   12201             :     end subroutine
   12202             : #endif
   12203             : 
   12204             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12205             : 
   12206             : #if RK5_ENABLED
   12207             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_RK5(array, pattern, replacement, instance, sorted, unique)
   12208             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12209             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_RK5
   12210             : #endif
   12211             :         use pm_kind, only: RKC => RK5
   12212             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   12213             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   12214             :         real(RKC)               , intent(in)                    :: replacement
   12215             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12216             :         logical(LK)             , intent(in)    , optional      :: sorted
   12217             :         logical(LK)             , intent(in)    , optional      :: unique
   12218             :     end subroutine
   12219             : #endif
   12220             : 
   12221             : #if RK4_ENABLED
   12222             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_RK4(array, pattern, replacement, instance, sorted, unique)
   12223             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12224             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_RK4
   12225             : #endif
   12226             :         use pm_kind, only: RKC => RK4
   12227             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   12228             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   12229             :         real(RKC)               , intent(in)                    :: replacement
   12230             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12231             :         logical(LK)             , intent(in)    , optional      :: sorted
   12232             :         logical(LK)             , intent(in)    , optional      :: unique
   12233             :     end subroutine
   12234             : #endif
   12235             : 
   12236             : #if RK3_ENABLED
   12237             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_RK3(array, pattern, replacement, instance, sorted, unique)
   12238             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12239             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_RK3
   12240             : #endif
   12241             :         use pm_kind, only: RKC => RK3
   12242             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   12243             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   12244             :         real(RKC)               , intent(in)                    :: replacement
   12245             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12246             :         logical(LK)             , intent(in)    , optional      :: sorted
   12247             :         logical(LK)             , intent(in)    , optional      :: unique
   12248             :     end subroutine
   12249             : #endif
   12250             : 
   12251             : #if RK2_ENABLED
   12252             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_RK2(array, pattern, replacement, instance, sorted, unique)
   12253             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12254             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_RK2
   12255             : #endif
   12256             :         use pm_kind, only: RKC => RK2
   12257             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   12258             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   12259             :         real(RKC)               , intent(in)                    :: replacement
   12260             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12261             :         logical(LK)             , intent(in)    , optional      :: sorted
   12262             :         logical(LK)             , intent(in)    , optional      :: unique
   12263             :     end subroutine
   12264             : 
   12265             : #endif
   12266             : 
   12267             : #if RK1_ENABLED
   12268             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D0_RK1(array, pattern, replacement, instance, sorted, unique)
   12269             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12270             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D0_RK1
   12271             : #endif
   12272             :         use pm_kind, only: RKC => RK1
   12273             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   12274             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   12275             :         real(RKC)               , intent(in)                    :: replacement
   12276             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12277             :         logical(LK)             , intent(in)    , optional      :: sorted
   12278             :         logical(LK)             , intent(in)    , optional      :: unique
   12279             :     end subroutine
   12280             : #endif
   12281             : 
   12282             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12283             : 
   12284             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12285             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12286             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12287             : 
   12288             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12289             : 
   12290             : #if SK5_ENABLED
   12291             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_SK5(array, pattern, replacement, instance, sorted, unique)
   12292             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12293             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_SK5
   12294             : #endif
   12295             :         use pm_kind, only: SKC => SK5
   12296             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   12297             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   12298             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   12299             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12300             :         logical(LK)             , intent(in)    , optional      :: sorted
   12301             :         logical(LK)             , intent(in)    , optional      :: unique
   12302             :     end subroutine
   12303             : #endif
   12304             : 
   12305             : #if SK4_ENABLED
   12306             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_SK4(array, pattern, replacement, instance, sorted, unique)
   12307             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12308             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_SK4
   12309             : #endif
   12310             :         use pm_kind, only: SKC => SK4
   12311             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   12312             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   12313             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   12314             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12315             :         logical(LK)             , intent(in)    , optional      :: sorted
   12316             :         logical(LK)             , intent(in)    , optional      :: unique
   12317             :     end subroutine
   12318             : #endif
   12319             : 
   12320             : #if SK3_ENABLED
   12321             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_SK3(array, pattern, replacement, instance, sorted, unique)
   12322             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12323             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_SK3
   12324             : #endif
   12325             :         use pm_kind, only: SKC => SK3
   12326             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   12327             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   12328             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   12329             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12330             :         logical(LK)             , intent(in)    , optional      :: sorted
   12331             :         logical(LK)             , intent(in)    , optional      :: unique
   12332             :     end subroutine
   12333             : #endif
   12334             : 
   12335             : #if SK2_ENABLED
   12336             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_SK2(array, pattern, replacement, instance, sorted, unique)
   12337             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12338             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_SK2
   12339             : #endif
   12340             :         use pm_kind, only: SKC => SK2
   12341             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   12342             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   12343             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   12344             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12345             :         logical(LK)             , intent(in)    , optional      :: sorted
   12346             :         logical(LK)             , intent(in)    , optional      :: unique
   12347             :     end subroutine
   12348             : 
   12349             : #endif
   12350             : 
   12351             : #if SK1_ENABLED
   12352             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_SK1(array, pattern, replacement, instance, sorted, unique)
   12353             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12354             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_SK1
   12355             : #endif
   12356             :         use pm_kind, only: SKC => SK1
   12357             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   12358             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   12359             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   12360             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12361             :         logical(LK)             , intent(in)    , optional      :: sorted
   12362             :         logical(LK)             , intent(in)    , optional      :: unique
   12363             :     end subroutine
   12364             : #endif
   12365             : 
   12366             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12367             : 
   12368             : #if IK5_ENABLED
   12369             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_IK5(array, pattern, replacement, instance, sorted, unique)
   12370             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12371             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_IK5
   12372             : #endif
   12373             :         use pm_kind, only: IKC => IK5
   12374             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12375             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   12376             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   12377             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12378             :         logical(LK)             , intent(in)    , optional      :: sorted
   12379             :         logical(LK)             , intent(in)    , optional      :: unique
   12380             :     end subroutine
   12381             : #endif
   12382             : 
   12383             : #if IK4_ENABLED
   12384             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_IK4(array, pattern, replacement, instance, sorted, unique)
   12385             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12386             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_IK4
   12387             : #endif
   12388             :         use pm_kind, only: IKC => IK4
   12389             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12390             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   12391             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   12392             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12393             :         logical(LK)             , intent(in)    , optional      :: sorted
   12394             :         logical(LK)             , intent(in)    , optional      :: unique
   12395             :     end subroutine
   12396             : #endif
   12397             : 
   12398             : #if IK3_ENABLED
   12399             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_IK3(array, pattern, replacement, instance, sorted, unique)
   12400             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12401             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_IK3
   12402             : #endif
   12403             :         use pm_kind, only: IKC => IK3
   12404             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12405             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   12406             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   12407             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12408             :         logical(LK)             , intent(in)    , optional      :: sorted
   12409             :         logical(LK)             , intent(in)    , optional      :: unique
   12410             :     end subroutine
   12411             : #endif
   12412             : 
   12413             : #if IK2_ENABLED
   12414             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_IK2(array, pattern, replacement, instance, sorted, unique)
   12415             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12416             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_IK2
   12417             : #endif
   12418             :         use pm_kind, only: IKC => IK2
   12419             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12420             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   12421             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   12422             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12423             :         logical(LK)             , intent(in)    , optional      :: sorted
   12424             :         logical(LK)             , intent(in)    , optional      :: unique
   12425             :     end subroutine
   12426             : 
   12427             : #endif
   12428             : 
   12429             : #if IK1_ENABLED
   12430             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_IK1(array, pattern, replacement, instance, sorted, unique)
   12431             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12432             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_IK1
   12433             : #endif
   12434             :         use pm_kind, only: IKC => IK1
   12435             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12436             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   12437             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   12438             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12439             :         logical(LK)             , intent(in)    , optional      :: sorted
   12440             :         logical(LK)             , intent(in)    , optional      :: unique
   12441             :     end subroutine
   12442             : #endif
   12443             : 
   12444             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12445             : 
   12446             : #if LK5_ENABLED
   12447             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_LK5(array, pattern, replacement, instance, sorted, unique)
   12448             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12449             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_LK5
   12450             : #endif
   12451             :         use pm_kind, only: LKC => LK5
   12452             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12453             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   12454             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   12455             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12456             :         logical(LK)             , intent(in)    , optional      :: sorted
   12457             :         logical(LK)             , intent(in)    , optional      :: unique
   12458             :     end subroutine
   12459             : #endif
   12460             : 
   12461             : #if LK4_ENABLED
   12462             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_LK4(array, pattern, replacement, instance, sorted, unique)
   12463             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12464             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_LK4
   12465             : #endif
   12466             :         use pm_kind, only: LKC => LK4
   12467             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12468             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   12469             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   12470             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12471             :         logical(LK)             , intent(in)    , optional      :: sorted
   12472             :         logical(LK)             , intent(in)    , optional      :: unique
   12473             :     end subroutine
   12474             : #endif
   12475             : 
   12476             : #if LK3_ENABLED
   12477             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_LK3(array, pattern, replacement, instance, sorted, unique)
   12478             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12479             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_LK3
   12480             : #endif
   12481             :         use pm_kind, only: LKC => LK3
   12482             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12483             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   12484             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   12485             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12486             :         logical(LK)             , intent(in)    , optional      :: sorted
   12487             :         logical(LK)             , intent(in)    , optional      :: unique
   12488             :     end subroutine
   12489             : #endif
   12490             : 
   12491             : #if LK2_ENABLED
   12492             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_LK2(array, pattern, replacement, instance, sorted, unique)
   12493             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12494             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_LK2
   12495             : #endif
   12496             :         use pm_kind, only: LKC => LK2
   12497             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12498             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   12499             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   12500             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12501             :         logical(LK)             , intent(in)    , optional      :: sorted
   12502             :         logical(LK)             , intent(in)    , optional      :: unique
   12503             :     end subroutine
   12504             : 
   12505             : #endif
   12506             : 
   12507             : #if LK1_ENABLED
   12508             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_LK1(array, pattern, replacement, instance, sorted, unique)
   12509             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12510             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_LK1
   12511             : #endif
   12512             :         use pm_kind, only: LKC => LK1
   12513             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12514             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   12515             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   12516             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12517             :         logical(LK)             , intent(in)    , optional      :: sorted
   12518             :         logical(LK)             , intent(in)    , optional      :: unique
   12519             :     end subroutine
   12520             : #endif
   12521             : 
   12522             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12523             : 
   12524             : #if CK5_ENABLED
   12525             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_CK5(array, pattern, replacement, instance, sorted, unique)
   12526             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12527             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_CK5
   12528             : #endif
   12529             :         use pm_kind, only: CKC => CK5
   12530             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   12531             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   12532             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   12533             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12534             :         logical(LK)             , intent(in)    , optional      :: sorted
   12535             :         logical(LK)             , intent(in)    , optional      :: unique
   12536             :     end subroutine
   12537             : #endif
   12538             : 
   12539             : #if CK4_ENABLED
   12540             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_CK4(array, pattern, replacement, instance, sorted, unique)
   12541             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12542             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_CK4
   12543             : #endif
   12544             :         use pm_kind, only: CKC => CK4
   12545             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   12546             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   12547             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   12548             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12549             :         logical(LK)             , intent(in)    , optional      :: sorted
   12550             :         logical(LK)             , intent(in)    , optional      :: unique
   12551             :     end subroutine
   12552             : #endif
   12553             : 
   12554             : #if CK3_ENABLED
   12555             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_CK3(array, pattern, replacement, instance, sorted, unique)
   12556             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12557             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_CK3
   12558             : #endif
   12559             :         use pm_kind, only: CKC => CK3
   12560             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   12561             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   12562             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   12563             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12564             :         logical(LK)             , intent(in)    , optional      :: sorted
   12565             :         logical(LK)             , intent(in)    , optional      :: unique
   12566             :     end subroutine
   12567             : #endif
   12568             : 
   12569             : #if CK2_ENABLED
   12570             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_CK2(array, pattern, replacement, instance, sorted, unique)
   12571             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12572             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_CK2
   12573             : #endif
   12574             :         use pm_kind, only: CKC => CK2
   12575             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   12576             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   12577             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   12578             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12579             :         logical(LK)             , intent(in)    , optional      :: sorted
   12580             :         logical(LK)             , intent(in)    , optional      :: unique
   12581             :     end subroutine
   12582             : 
   12583             : #endif
   12584             : 
   12585             : #if CK1_ENABLED
   12586             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_CK1(array, pattern, replacement, instance, sorted, unique)
   12587             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12588             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_CK1
   12589             : #endif
   12590             :         use pm_kind, only: CKC => CK1
   12591             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   12592             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   12593             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   12594             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12595             :         logical(LK)             , intent(in)    , optional      :: sorted
   12596             :         logical(LK)             , intent(in)    , optional      :: unique
   12597             :     end subroutine
   12598             : #endif
   12599             : 
   12600             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12601             : 
   12602             : #if RK5_ENABLED
   12603             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_RK5(array, pattern, replacement, instance, sorted, unique)
   12604             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12605             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_RK5
   12606             : #endif
   12607             :         use pm_kind, only: RKC => RK5
   12608             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   12609             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   12610             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   12611             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12612             :         logical(LK)             , intent(in)    , optional      :: sorted
   12613             :         logical(LK)             , intent(in)    , optional      :: unique
   12614             :     end subroutine
   12615             : #endif
   12616             : 
   12617             : #if RK4_ENABLED
   12618             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_RK4(array, pattern, replacement, instance, sorted, unique)
   12619             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12620             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_RK4
   12621             : #endif
   12622             :         use pm_kind, only: RKC => RK4
   12623             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   12624             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   12625             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   12626             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12627             :         logical(LK)             , intent(in)    , optional      :: sorted
   12628             :         logical(LK)             , intent(in)    , optional      :: unique
   12629             :     end subroutine
   12630             : #endif
   12631             : 
   12632             : #if RK3_ENABLED
   12633             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_RK3(array, pattern, replacement, instance, sorted, unique)
   12634             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12635             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_RK3
   12636             : #endif
   12637             :         use pm_kind, only: RKC => RK3
   12638             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   12639             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   12640             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   12641             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12642             :         logical(LK)             , intent(in)    , optional      :: sorted
   12643             :         logical(LK)             , intent(in)    , optional      :: unique
   12644             :     end subroutine
   12645             : #endif
   12646             : 
   12647             : #if RK2_ENABLED
   12648             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_RK2(array, pattern, replacement, instance, sorted, unique)
   12649             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12650             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_RK2
   12651             : #endif
   12652             :         use pm_kind, only: RKC => RK2
   12653             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   12654             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   12655             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   12656             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12657             :         logical(LK)             , intent(in)    , optional      :: sorted
   12658             :         logical(LK)             , intent(in)    , optional      :: unique
   12659             :     end subroutine
   12660             : 
   12661             : #endif
   12662             : 
   12663             : #if RK1_ENABLED
   12664             :     PURE module subroutine setReplacedDefComCusIns_D1_D1_D1_RK1(array, pattern, replacement, instance, sorted, unique)
   12665             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12666             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedDefComCusIns_D1_D1_D1_RK1
   12667             : #endif
   12668             :         use pm_kind, only: RKC => RK1
   12669             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   12670             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   12671             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   12672             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12673             :         logical(LK)             , intent(in)    , optional      :: sorted
   12674             :         logical(LK)             , intent(in)    , optional      :: unique
   12675             :     end subroutine
   12676             : #endif
   12677             : 
   12678             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12679             : 
   12680             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12681             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12682             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12683             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12684             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12685             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12686             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12687             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12688             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12689             : 
   12690             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12691             : 
   12692             : #if SK5_ENABLED
   12693             :     module subroutine setReplacedCusComCusIns_D0_D0_D0_SK5(array, pattern, replacement, iseq, instance, sorted, unique)
   12694             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12695             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D0_D0_D0_SK5
   12696             : #endif
   12697             :         use pm_kind, only: SKC => SK5
   12698             :         character(:,SKC)        , intent(inout) , allocatable   :: array
   12699             :         character(*,SKC)        , intent(in)                    :: pattern
   12700             :         character(*,SKC)        , intent(in)                    :: replacement
   12701             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
   12702             :         procedure(logical(LK))                                  :: iseq
   12703             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12704             :         logical(LK)             , intent(in)    , optional      :: sorted
   12705             :         logical(LK)             , intent(in)    , optional      :: unique
   12706             :     end subroutine
   12707             : #endif
   12708             : 
   12709             : #if SK4_ENABLED
   12710             :     module subroutine setReplacedCusComCusIns_D0_D0_D0_SK4(array, pattern, replacement, iseq, instance, sorted, unique)
   12711             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12712             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D0_D0_D0_SK4
   12713             : #endif
   12714             :         use pm_kind, only: SKC => SK4
   12715             :         character(:,SKC)        , intent(inout) , allocatable   :: array
   12716             :         character(*,SKC)        , intent(in)                    :: pattern
   12717             :         character(*,SKC)        , intent(in)                    :: replacement
   12718             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
   12719             :         procedure(logical(LK))                                  :: iseq
   12720             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12721             :         logical(LK)             , intent(in)    , optional      :: sorted
   12722             :         logical(LK)             , intent(in)    , optional      :: unique
   12723             :     end subroutine
   12724             : #endif
   12725             : 
   12726             : #if SK3_ENABLED
   12727             :     module subroutine setReplacedCusComCusIns_D0_D0_D0_SK3(array, pattern, replacement, iseq, instance, sorted, unique)
   12728             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12729             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D0_D0_D0_SK3
   12730             : #endif
   12731             :         use pm_kind, only: SKC => SK3
   12732             :         character(:,SKC)        , intent(inout) , allocatable   :: array
   12733             :         character(*,SKC)        , intent(in)                    :: pattern
   12734             :         character(*,SKC)        , intent(in)                    :: replacement
   12735             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
   12736             :         procedure(logical(LK))                                  :: iseq
   12737             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12738             :         logical(LK)             , intent(in)    , optional      :: sorted
   12739             :         logical(LK)             , intent(in)    , optional      :: unique
   12740             :     end subroutine
   12741             : #endif
   12742             : 
   12743             : #if SK2_ENABLED
   12744             :     module subroutine setReplacedCusComCusIns_D0_D0_D0_SK2(array, pattern, replacement, iseq, instance, sorted, unique)
   12745             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12746             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D0_D0_D0_SK2
   12747             : #endif
   12748             :         use pm_kind, only: SKC => SK2
   12749             :         character(:,SKC)        , intent(inout) , allocatable   :: array
   12750             :         character(*,SKC)        , intent(in)                    :: pattern
   12751             :         character(*,SKC)        , intent(in)                    :: replacement
   12752             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
   12753             :         procedure(logical(LK))                                  :: iseq
   12754             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12755             :         logical(LK)             , intent(in)    , optional      :: sorted
   12756             :         logical(LK)             , intent(in)    , optional      :: unique
   12757             :     end subroutine
   12758             : 
   12759             : #endif
   12760             : 
   12761             : #if SK1_ENABLED
   12762             :     module subroutine setReplacedCusComCusIns_D0_D0_D0_SK1(array, pattern, replacement, iseq, instance, sorted, unique)
   12763             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12764             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D0_D0_D0_SK1
   12765             : #endif
   12766             :         use pm_kind, only: SKC => SK1
   12767             :         character(:,SKC)        , intent(inout) , allocatable   :: array
   12768             :         character(*,SKC)        , intent(in)                    :: pattern
   12769             :         character(*,SKC)        , intent(in)                    :: replacement
   12770             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
   12771             :         procedure(logical(LK))                                  :: iseq
   12772             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12773             :         logical(LK)             , intent(in)    , optional      :: sorted
   12774             :         logical(LK)             , intent(in)    , optional      :: unique
   12775             :     end subroutine
   12776             : #endif
   12777             : 
   12778             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12779             : 
   12780             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12781             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12782             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12783             : 
   12784             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12785             : 
   12786             : #if SK5_ENABLED
   12787             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_SK5(array, pattern, replacement, iseq, instance, sorted, unique)
   12788             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12789             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_SK5
   12790             : #endif
   12791             :         use pm_kind, only: SKC => SK5
   12792             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   12793             :         character(*,SKC)        , intent(in)                    :: pattern
   12794             :         character(*,SKC)        , intent(in)                    :: replacement
   12795             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
   12796             :         procedure(logical(LK))                                  :: iseq
   12797             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12798             :         logical(LK)             , intent(in)    , optional      :: sorted
   12799             :         logical(LK)             , intent(in)    , optional      :: unique
   12800             :     end subroutine
   12801             : #endif
   12802             : 
   12803             : #if SK4_ENABLED
   12804             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_SK4(array, pattern, replacement, iseq, instance, sorted, unique)
   12805             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12806             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_SK4
   12807             : #endif
   12808             :         use pm_kind, only: SKC => SK4
   12809             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   12810             :         character(*,SKC)        , intent(in)                    :: pattern
   12811             :         character(*,SKC)        , intent(in)                    :: replacement
   12812             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
   12813             :         procedure(logical(LK))                                  :: iseq
   12814             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12815             :         logical(LK)             , intent(in)    , optional      :: sorted
   12816             :         logical(LK)             , intent(in)    , optional      :: unique
   12817             :     end subroutine
   12818             : #endif
   12819             : 
   12820             : #if SK3_ENABLED
   12821             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_SK3(array, pattern, replacement, iseq, instance, sorted, unique)
   12822             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12823             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_SK3
   12824             : #endif
   12825             :         use pm_kind, only: SKC => SK3
   12826             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   12827             :         character(*,SKC)        , intent(in)                    :: pattern
   12828             :         character(*,SKC)        , intent(in)                    :: replacement
   12829             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
   12830             :         procedure(logical(LK))                                  :: iseq
   12831             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12832             :         logical(LK)             , intent(in)    , optional      :: sorted
   12833             :         logical(LK)             , intent(in)    , optional      :: unique
   12834             :     end subroutine
   12835             : #endif
   12836             : 
   12837             : #if SK2_ENABLED
   12838             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_SK2(array, pattern, replacement, iseq, instance, sorted, unique)
   12839             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12840             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_SK2
   12841             : #endif
   12842             :         use pm_kind, only: SKC => SK2
   12843             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   12844             :         character(*,SKC)        , intent(in)                    :: pattern
   12845             :         character(*,SKC)        , intent(in)                    :: replacement
   12846             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
   12847             :         procedure(logical(LK))                                  :: iseq
   12848             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12849             :         logical(LK)             , intent(in)    , optional      :: sorted
   12850             :         logical(LK)             , intent(in)    , optional      :: unique
   12851             :     end subroutine
   12852             : 
   12853             : #endif
   12854             : 
   12855             : #if SK1_ENABLED
   12856             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_SK1(array, pattern, replacement, iseq, instance, sorted, unique)
   12857             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12858             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_SK1
   12859             : #endif
   12860             :         use pm_kind, only: SKC => SK1
   12861             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   12862             :         character(*,SKC)        , intent(in)                    :: pattern
   12863             :         character(*,SKC)        , intent(in)                    :: replacement
   12864             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
   12865             :         procedure(logical(LK))                                  :: iseq
   12866             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12867             :         logical(LK)             , intent(in)    , optional      :: sorted
   12868             :         logical(LK)             , intent(in)    , optional      :: unique
   12869             :     end subroutine
   12870             : #endif
   12871             : 
   12872             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12873             : 
   12874             : #if IK5_ENABLED
   12875             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_IK5(array, pattern, replacement, iseq, instance, sorted, unique)
   12876             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12877             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_IK5
   12878             : #endif
   12879             :         use pm_kind, only: IKC => IK5
   12880             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12881             :         integer(IKC)            , intent(in)                    :: pattern
   12882             :         integer(IKC)            , intent(in)                    :: replacement
   12883             :        !procedure(iseq_D0_D0_IK5)                               :: iseq
   12884             :         procedure(logical(LK))                                  :: iseq
   12885             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12886             :         logical(LK)             , intent(in)    , optional      :: sorted
   12887             :         logical(LK)             , intent(in)    , optional      :: unique
   12888             :     end subroutine
   12889             : #endif
   12890             : 
   12891             : #if IK4_ENABLED
   12892             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_IK4(array, pattern, replacement, iseq, instance, sorted, unique)
   12893             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12894             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_IK4
   12895             : #endif
   12896             :         use pm_kind, only: IKC => IK4
   12897             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12898             :         integer(IKC)            , intent(in)                    :: pattern
   12899             :         integer(IKC)            , intent(in)                    :: replacement
   12900             :        !procedure(iseq_D0_D0_IK4)                               :: iseq
   12901             :         procedure(logical(LK))                                  :: iseq
   12902             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12903             :         logical(LK)             , intent(in)    , optional      :: sorted
   12904             :         logical(LK)             , intent(in)    , optional      :: unique
   12905             :     end subroutine
   12906             : #endif
   12907             : 
   12908             : #if IK3_ENABLED
   12909             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_IK3(array, pattern, replacement, iseq, instance, sorted, unique)
   12910             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12911             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_IK3
   12912             : #endif
   12913             :         use pm_kind, only: IKC => IK3
   12914             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12915             :         integer(IKC)            , intent(in)                    :: pattern
   12916             :         integer(IKC)            , intent(in)                    :: replacement
   12917             :        !procedure(iseq_D0_D0_IK3)                               :: iseq
   12918             :         procedure(logical(LK))                                  :: iseq
   12919             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12920             :         logical(LK)             , intent(in)    , optional      :: sorted
   12921             :         logical(LK)             , intent(in)    , optional      :: unique
   12922             :     end subroutine
   12923             : #endif
   12924             : 
   12925             : #if IK2_ENABLED
   12926             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_IK2(array, pattern, replacement, iseq, instance, sorted, unique)
   12927             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12928             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_IK2
   12929             : #endif
   12930             :         use pm_kind, only: IKC => IK2
   12931             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12932             :         integer(IKC)            , intent(in)                    :: pattern
   12933             :         integer(IKC)            , intent(in)                    :: replacement
   12934             :        !procedure(iseq_D0_D0_IK2)                               :: iseq
   12935             :         procedure(logical(LK))                                  :: iseq
   12936             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12937             :         logical(LK)             , intent(in)    , optional      :: sorted
   12938             :         logical(LK)             , intent(in)    , optional      :: unique
   12939             :     end subroutine
   12940             : 
   12941             : #endif
   12942             : 
   12943             : #if IK1_ENABLED
   12944             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_IK1(array, pattern, replacement, iseq, instance, sorted, unique)
   12945             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12946             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_IK1
   12947             : #endif
   12948             :         use pm_kind, only: IKC => IK1
   12949             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   12950             :         integer(IKC)            , intent(in)                    :: pattern
   12951             :         integer(IKC)            , intent(in)                    :: replacement
   12952             :        !procedure(iseq_D0_D0_IK1)                               :: iseq
   12953             :         procedure(logical(LK))                                  :: iseq
   12954             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12955             :         logical(LK)             , intent(in)    , optional      :: sorted
   12956             :         logical(LK)             , intent(in)    , optional      :: unique
   12957             :     end subroutine
   12958             : #endif
   12959             : 
   12960             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   12961             : 
   12962             : #if LK5_ENABLED
   12963             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_LK5(array, pattern, replacement, iseq, instance, sorted, unique)
   12964             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12965             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_LK5
   12966             : #endif
   12967             :         use pm_kind, only: LKC => LK5
   12968             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12969             :         logical(LKC)            , intent(in)                    :: pattern
   12970             :         logical(LKC)            , intent(in)                    :: replacement
   12971             :        !procedure(iseq_D0_D0_LK5)                               :: iseq
   12972             :         procedure(logical(LK))                                  :: iseq
   12973             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12974             :         logical(LK)             , intent(in)    , optional      :: sorted
   12975             :         logical(LK)             , intent(in)    , optional      :: unique
   12976             :     end subroutine
   12977             : #endif
   12978             : 
   12979             : #if LK4_ENABLED
   12980             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_LK4(array, pattern, replacement, iseq, instance, sorted, unique)
   12981             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12982             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_LK4
   12983             : #endif
   12984             :         use pm_kind, only: LKC => LK4
   12985             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   12986             :         logical(LKC)            , intent(in)                    :: pattern
   12987             :         logical(LKC)            , intent(in)                    :: replacement
   12988             :        !procedure(iseq_D0_D0_LK4)                               :: iseq
   12989             :         procedure(logical(LK))                                  :: iseq
   12990             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   12991             :         logical(LK)             , intent(in)    , optional      :: sorted
   12992             :         logical(LK)             , intent(in)    , optional      :: unique
   12993             :     end subroutine
   12994             : #endif
   12995             : 
   12996             : #if LK3_ENABLED
   12997             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_LK3(array, pattern, replacement, iseq, instance, sorted, unique)
   12998             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   12999             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_LK3
   13000             : #endif
   13001             :         use pm_kind, only: LKC => LK3
   13002             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13003             :         logical(LKC)            , intent(in)                    :: pattern
   13004             :         logical(LKC)            , intent(in)                    :: replacement
   13005             :        !procedure(iseq_D0_D0_LK3)                               :: iseq
   13006             :         procedure(logical(LK))                                  :: iseq
   13007             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13008             :         logical(LK)             , intent(in)    , optional      :: sorted
   13009             :         logical(LK)             , intent(in)    , optional      :: unique
   13010             :     end subroutine
   13011             : #endif
   13012             : 
   13013             : #if LK2_ENABLED
   13014             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_LK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13015             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13016             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_LK2
   13017             : #endif
   13018             :         use pm_kind, only: LKC => LK2
   13019             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13020             :         logical(LKC)            , intent(in)                    :: pattern
   13021             :         logical(LKC)            , intent(in)                    :: replacement
   13022             :        !procedure(iseq_D0_D0_LK2)                               :: iseq
   13023             :         procedure(logical(LK))                                  :: iseq
   13024             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13025             :         logical(LK)             , intent(in)    , optional      :: sorted
   13026             :         logical(LK)             , intent(in)    , optional      :: unique
   13027             :     end subroutine
   13028             : 
   13029             : #endif
   13030             : 
   13031             : #if LK1_ENABLED
   13032             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_LK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13033             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13034             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_LK1
   13035             : #endif
   13036             :         use pm_kind, only: LKC => LK1
   13037             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13038             :         logical(LKC)            , intent(in)                    :: pattern
   13039             :         logical(LKC)            , intent(in)                    :: replacement
   13040             :        !procedure(iseq_D0_D0_LK1)                               :: iseq
   13041             :         procedure(logical(LK))                                  :: iseq
   13042             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13043             :         logical(LK)             , intent(in)    , optional      :: sorted
   13044             :         logical(LK)             , intent(in)    , optional      :: unique
   13045             :     end subroutine
   13046             : #endif
   13047             : 
   13048             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13049             : 
   13050             : #if CK5_ENABLED
   13051             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_CK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13052             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13053             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_CK5
   13054             : #endif
   13055             :         use pm_kind, only: CKC => CK5
   13056             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13057             :         complex(CKC)            , intent(in)                    :: pattern
   13058             :         complex(CKC)            , intent(in)                    :: replacement
   13059             :        !procedure(iseq_D0_D0_CK5)                               :: iseq
   13060             :         procedure(logical(LK))                                  :: iseq
   13061             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13062             :         logical(LK)             , intent(in)    , optional      :: sorted
   13063             :         logical(LK)             , intent(in)    , optional      :: unique
   13064             :     end subroutine
   13065             : #endif
   13066             : 
   13067             : #if CK4_ENABLED
   13068             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_CK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13069             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13070             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_CK4
   13071             : #endif
   13072             :         use pm_kind, only: CKC => CK4
   13073             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13074             :         complex(CKC)            , intent(in)                    :: pattern
   13075             :         complex(CKC)            , intent(in)                    :: replacement
   13076             :        !procedure(iseq_D0_D0_CK4)                               :: iseq
   13077             :         procedure(logical(LK))                                  :: iseq
   13078             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13079             :         logical(LK)             , intent(in)    , optional      :: sorted
   13080             :         logical(LK)             , intent(in)    , optional      :: unique
   13081             :     end subroutine
   13082             : #endif
   13083             : 
   13084             : #if CK3_ENABLED
   13085             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_CK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13086             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13087             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_CK3
   13088             : #endif
   13089             :         use pm_kind, only: CKC => CK3
   13090             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13091             :         complex(CKC)            , intent(in)                    :: pattern
   13092             :         complex(CKC)            , intent(in)                    :: replacement
   13093             :        !procedure(iseq_D0_D0_CK3)                               :: iseq
   13094             :         procedure(logical(LK))                                  :: iseq
   13095             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13096             :         logical(LK)             , intent(in)    , optional      :: sorted
   13097             :         logical(LK)             , intent(in)    , optional      :: unique
   13098             :     end subroutine
   13099             : #endif
   13100             : 
   13101             : #if CK2_ENABLED
   13102             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_CK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13103             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13104             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_CK2
   13105             : #endif
   13106             :         use pm_kind, only: CKC => CK2
   13107             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13108             :         complex(CKC)            , intent(in)                    :: pattern
   13109             :         complex(CKC)            , intent(in)                    :: replacement
   13110             :        !procedure(iseq_D0_D0_CK2)                               :: iseq
   13111             :         procedure(logical(LK))                                  :: iseq
   13112             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13113             :         logical(LK)             , intent(in)    , optional      :: sorted
   13114             :         logical(LK)             , intent(in)    , optional      :: unique
   13115             :     end subroutine
   13116             : 
   13117             : #endif
   13118             : 
   13119             : #if CK1_ENABLED
   13120             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_CK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13121             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13122             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_CK1
   13123             : #endif
   13124             :         use pm_kind, only: CKC => CK1
   13125             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13126             :         complex(CKC)            , intent(in)                    :: pattern
   13127             :         complex(CKC)            , intent(in)                    :: replacement
   13128             :        !procedure(iseq_D0_D0_CK1)                               :: iseq
   13129             :         procedure(logical(LK))                                  :: iseq
   13130             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13131             :         logical(LK)             , intent(in)    , optional      :: sorted
   13132             :         logical(LK)             , intent(in)    , optional      :: unique
   13133             :     end subroutine
   13134             : #endif
   13135             : 
   13136             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13137             : 
   13138             : #if RK5_ENABLED
   13139             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_RK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13140             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13141             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_RK5
   13142             : #endif
   13143             :         use pm_kind, only: RKC => RK5
   13144             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   13145             :         real(RKC)               , intent(in)                    :: pattern
   13146             :         real(RKC)               , intent(in)                    :: replacement
   13147             :        !procedure(iseq_D0_D0_RK5)                               :: iseq
   13148             :         procedure(logical(LK))                                  :: iseq
   13149             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13150             :         logical(LK)             , intent(in)    , optional      :: sorted
   13151             :         logical(LK)             , intent(in)    , optional      :: unique
   13152             :     end subroutine
   13153             : #endif
   13154             : 
   13155             : #if RK4_ENABLED
   13156             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_RK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13157             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13158             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_RK4
   13159             : #endif
   13160             :         use pm_kind, only: RKC => RK4
   13161             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   13162             :         real(RKC)               , intent(in)                    :: pattern
   13163             :         real(RKC)               , intent(in)                    :: replacement
   13164             :        !procedure(iseq_D0_D0_RK4)                               :: iseq
   13165             :         procedure(logical(LK))                                  :: iseq
   13166             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13167             :         logical(LK)             , intent(in)    , optional      :: sorted
   13168             :         logical(LK)             , intent(in)    , optional      :: unique
   13169             :     end subroutine
   13170             : #endif
   13171             : 
   13172             : #if RK3_ENABLED
   13173             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_RK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13174             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13175             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_RK3
   13176             : #endif
   13177             :         use pm_kind, only: RKC => RK3
   13178             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   13179             :         real(RKC)               , intent(in)                    :: pattern
   13180             :         real(RKC)               , intent(in)                    :: replacement
   13181             :        !procedure(iseq_D0_D0_RK3)                               :: iseq
   13182             :         procedure(logical(LK))                                  :: iseq
   13183             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13184             :         logical(LK)             , intent(in)    , optional      :: sorted
   13185             :         logical(LK)             , intent(in)    , optional      :: unique
   13186             :     end subroutine
   13187             : #endif
   13188             : 
   13189             : #if RK2_ENABLED
   13190             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_RK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13191             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13192             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_RK2
   13193             : #endif
   13194             :         use pm_kind, only: RKC => RK2
   13195             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   13196             :         real(RKC)               , intent(in)                    :: pattern
   13197             :         real(RKC)               , intent(in)                    :: replacement
   13198             :        !procedure(iseq_D0_D0_RK2)                               :: iseq
   13199             :         procedure(logical(LK))                                  :: iseq
   13200             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13201             :         logical(LK)             , intent(in)    , optional      :: sorted
   13202             :         logical(LK)             , intent(in)    , optional      :: unique
   13203             :     end subroutine
   13204             : 
   13205             : #endif
   13206             : 
   13207             : #if RK1_ENABLED
   13208             :     module subroutine setReplacedCusComCusIns_D1_D0_D0_RK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13209             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13210             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D0_RK1
   13211             : #endif
   13212             :         use pm_kind, only: RKC => RK1
   13213             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   13214             :         real(RKC)               , intent(in)                    :: pattern
   13215             :         real(RKC)               , intent(in)                    :: replacement
   13216             :        !procedure(iseq_D0_D0_RK1)                               :: iseq
   13217             :         procedure(logical(LK))                                  :: iseq
   13218             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13219             :         logical(LK)             , intent(in)    , optional      :: sorted
   13220             :         logical(LK)             , intent(in)    , optional      :: unique
   13221             :     end subroutine
   13222             : #endif
   13223             : 
   13224             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13225             : 
   13226             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13227             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13228             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13229             : 
   13230             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13231             : 
   13232             : #if SK5_ENABLED
   13233             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_SK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13234             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13235             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_SK5
   13236             : #endif
   13237             :         use pm_kind, only: SKC => SK5
   13238             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   13239             :         character(*,SKC)        , intent(in)                    :: pattern
   13240             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   13241             :        !procedure(iseq_D0_D0_SK5)                               :: iseq
   13242             :         procedure(logical(LK))                                  :: iseq
   13243             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13244             :         logical(LK)             , intent(in)    , optional      :: sorted
   13245             :         logical(LK)             , intent(in)    , optional      :: unique
   13246             :     end subroutine
   13247             : #endif
   13248             : 
   13249             : #if SK4_ENABLED
   13250             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_SK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13251             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13252             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_SK4
   13253             : #endif
   13254             :         use pm_kind, only: SKC => SK4
   13255             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   13256             :         character(*,SKC)        , intent(in)                    :: pattern
   13257             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   13258             :        !procedure(iseq_D0_D0_SK4)                               :: iseq
   13259             :         procedure(logical(LK))                                  :: iseq
   13260             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13261             :         logical(LK)             , intent(in)    , optional      :: sorted
   13262             :         logical(LK)             , intent(in)    , optional      :: unique
   13263             :     end subroutine
   13264             : #endif
   13265             : 
   13266             : #if SK3_ENABLED
   13267             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_SK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13268             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13269             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_SK3
   13270             : #endif
   13271             :         use pm_kind, only: SKC => SK3
   13272             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   13273             :         character(*,SKC)        , intent(in)                    :: pattern
   13274             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   13275             :        !procedure(iseq_D0_D0_SK3)                               :: iseq
   13276             :         procedure(logical(LK))                                  :: iseq
   13277             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13278             :         logical(LK)             , intent(in)    , optional      :: sorted
   13279             :         logical(LK)             , intent(in)    , optional      :: unique
   13280             :     end subroutine
   13281             : #endif
   13282             : 
   13283             : #if SK2_ENABLED
   13284             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_SK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13285             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13286             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_SK2
   13287             : #endif
   13288             :         use pm_kind, only: SKC => SK2
   13289             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   13290             :         character(*,SKC)        , intent(in)                    :: pattern
   13291             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   13292             :        !procedure(iseq_D0_D0_SK2)                               :: iseq
   13293             :         procedure(logical(LK))                                  :: iseq
   13294             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13295             :         logical(LK)             , intent(in)    , optional      :: sorted
   13296             :         logical(LK)             , intent(in)    , optional      :: unique
   13297             :     end subroutine
   13298             : 
   13299             : #endif
   13300             : 
   13301             : #if SK1_ENABLED
   13302             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_SK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13303             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13304             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_SK1
   13305             : #endif
   13306             :         use pm_kind, only: SKC => SK1
   13307             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   13308             :         character(*,SKC)        , intent(in)                    :: pattern
   13309             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   13310             :        !procedure(iseq_D0_D0_SK1)                               :: iseq
   13311             :         procedure(logical(LK))                                  :: iseq
   13312             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13313             :         logical(LK)             , intent(in)    , optional      :: sorted
   13314             :         logical(LK)             , intent(in)    , optional      :: unique
   13315             :     end subroutine
   13316             : #endif
   13317             : 
   13318             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13319             : 
   13320             : #if IK5_ENABLED
   13321             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_IK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13322             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13323             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_IK5
   13324             : #endif
   13325             :         use pm_kind, only: IKC => IK5
   13326             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   13327             :         integer(IKC)            , intent(in)                    :: pattern
   13328             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   13329             :        !procedure(iseq_D0_D0_IK5)                               :: iseq
   13330             :         procedure(logical(LK))                                  :: iseq
   13331             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13332             :         logical(LK)             , intent(in)    , optional      :: sorted
   13333             :         logical(LK)             , intent(in)    , optional      :: unique
   13334             :     end subroutine
   13335             : #endif
   13336             : 
   13337             : #if IK4_ENABLED
   13338             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_IK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13339             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13340             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_IK4
   13341             : #endif
   13342             :         use pm_kind, only: IKC => IK4
   13343             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   13344             :         integer(IKC)            , intent(in)                    :: pattern
   13345             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   13346             :        !procedure(iseq_D0_D0_IK4)                               :: iseq
   13347             :         procedure(logical(LK))                                  :: iseq
   13348             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13349             :         logical(LK)             , intent(in)    , optional      :: sorted
   13350             :         logical(LK)             , intent(in)    , optional      :: unique
   13351             :     end subroutine
   13352             : #endif
   13353             : 
   13354             : #if IK3_ENABLED
   13355             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_IK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13356             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13357             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_IK3
   13358             : #endif
   13359             :         use pm_kind, only: IKC => IK3
   13360             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   13361             :         integer(IKC)            , intent(in)                    :: pattern
   13362             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   13363             :        !procedure(iseq_D0_D0_IK3)                               :: iseq
   13364             :         procedure(logical(LK))                                  :: iseq
   13365             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13366             :         logical(LK)             , intent(in)    , optional      :: sorted
   13367             :         logical(LK)             , intent(in)    , optional      :: unique
   13368             :     end subroutine
   13369             : #endif
   13370             : 
   13371             : #if IK2_ENABLED
   13372             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_IK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13373             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13374             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_IK2
   13375             : #endif
   13376             :         use pm_kind, only: IKC => IK2
   13377             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   13378             :         integer(IKC)            , intent(in)                    :: pattern
   13379             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   13380             :        !procedure(iseq_D0_D0_IK2)                               :: iseq
   13381             :         procedure(logical(LK))                                  :: iseq
   13382             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13383             :         logical(LK)             , intent(in)    , optional      :: sorted
   13384             :         logical(LK)             , intent(in)    , optional      :: unique
   13385             :     end subroutine
   13386             : 
   13387             : #endif
   13388             : 
   13389             : #if IK1_ENABLED
   13390             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_IK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13391             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13392             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_IK1
   13393             : #endif
   13394             :         use pm_kind, only: IKC => IK1
   13395             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   13396             :         integer(IKC)            , intent(in)                    :: pattern
   13397             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   13398             :        !procedure(iseq_D0_D0_IK1)                               :: iseq
   13399             :         procedure(logical(LK))                                  :: iseq
   13400             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13401             :         logical(LK)             , intent(in)    , optional      :: sorted
   13402             :         logical(LK)             , intent(in)    , optional      :: unique
   13403             :     end subroutine
   13404             : #endif
   13405             : 
   13406             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13407             : 
   13408             : #if LK5_ENABLED
   13409             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_LK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13410             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13411             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_LK5
   13412             : #endif
   13413             :         use pm_kind, only: LKC => LK5
   13414             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13415             :         logical(LKC)            , intent(in)                    :: pattern
   13416             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   13417             :        !procedure(iseq_D0_D0_LK5)                               :: iseq
   13418             :         procedure(logical(LK))                                  :: iseq
   13419             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13420             :         logical(LK)             , intent(in)    , optional      :: sorted
   13421             :         logical(LK)             , intent(in)    , optional      :: unique
   13422             :     end subroutine
   13423             : #endif
   13424             : 
   13425             : #if LK4_ENABLED
   13426             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_LK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13427             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13428             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_LK4
   13429             : #endif
   13430             :         use pm_kind, only: LKC => LK4
   13431             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13432             :         logical(LKC)            , intent(in)                    :: pattern
   13433             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   13434             :        !procedure(iseq_D0_D0_LK4)                               :: iseq
   13435             :         procedure(logical(LK))                                  :: iseq
   13436             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13437             :         logical(LK)             , intent(in)    , optional      :: sorted
   13438             :         logical(LK)             , intent(in)    , optional      :: unique
   13439             :     end subroutine
   13440             : #endif
   13441             : 
   13442             : #if LK3_ENABLED
   13443             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_LK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13444             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13445             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_LK3
   13446             : #endif
   13447             :         use pm_kind, only: LKC => LK3
   13448             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13449             :         logical(LKC)            , intent(in)                    :: pattern
   13450             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   13451             :        !procedure(iseq_D0_D0_LK3)                               :: iseq
   13452             :         procedure(logical(LK))                                  :: iseq
   13453             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13454             :         logical(LK)             , intent(in)    , optional      :: sorted
   13455             :         logical(LK)             , intent(in)    , optional      :: unique
   13456             :     end subroutine
   13457             : #endif
   13458             : 
   13459             : #if LK2_ENABLED
   13460             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_LK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13461             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13462             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_LK2
   13463             : #endif
   13464             :         use pm_kind, only: LKC => LK2
   13465             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13466             :         logical(LKC)            , intent(in)                    :: pattern
   13467             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   13468             :        !procedure(iseq_D0_D0_LK2)                               :: iseq
   13469             :         procedure(logical(LK))                                  :: iseq
   13470             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13471             :         logical(LK)             , intent(in)    , optional      :: sorted
   13472             :         logical(LK)             , intent(in)    , optional      :: unique
   13473             :     end subroutine
   13474             : 
   13475             : #endif
   13476             : 
   13477             : #if LK1_ENABLED
   13478             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_LK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13479             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13480             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_LK1
   13481             : #endif
   13482             :         use pm_kind, only: LKC => LK1
   13483             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13484             :         logical(LKC)            , intent(in)                    :: pattern
   13485             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   13486             :        !procedure(iseq_D0_D0_LK1)                               :: iseq
   13487             :         procedure(logical(LK))                                  :: iseq
   13488             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13489             :         logical(LK)             , intent(in)    , optional      :: sorted
   13490             :         logical(LK)             , intent(in)    , optional      :: unique
   13491             :     end subroutine
   13492             : #endif
   13493             : 
   13494             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13495             : 
   13496             : #if CK5_ENABLED
   13497             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_CK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13498             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13499             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_CK5
   13500             : #endif
   13501             :         use pm_kind, only: CKC => CK5
   13502             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13503             :         complex(CKC)            , intent(in)                    :: pattern
   13504             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   13505             :        !procedure(iseq_D0_D0_CK5)                               :: iseq
   13506             :         procedure(logical(LK))                                  :: iseq
   13507             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13508             :         logical(LK)             , intent(in)    , optional      :: sorted
   13509             :         logical(LK)             , intent(in)    , optional      :: unique
   13510             :     end subroutine
   13511             : #endif
   13512             : 
   13513             : #if CK4_ENABLED
   13514             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_CK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13515             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13516             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_CK4
   13517             : #endif
   13518             :         use pm_kind, only: CKC => CK4
   13519             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13520             :         complex(CKC)            , intent(in)                    :: pattern
   13521             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   13522             :        !procedure(iseq_D0_D0_CK4)                               :: iseq
   13523             :         procedure(logical(LK))                                  :: iseq
   13524             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13525             :         logical(LK)             , intent(in)    , optional      :: sorted
   13526             :         logical(LK)             , intent(in)    , optional      :: unique
   13527             :     end subroutine
   13528             : #endif
   13529             : 
   13530             : #if CK3_ENABLED
   13531             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_CK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13532             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13533             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_CK3
   13534             : #endif
   13535             :         use pm_kind, only: CKC => CK3
   13536             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13537             :         complex(CKC)            , intent(in)                    :: pattern
   13538             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   13539             :        !procedure(iseq_D0_D0_CK3)                               :: iseq
   13540             :         procedure(logical(LK))                                  :: iseq
   13541             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13542             :         logical(LK)             , intent(in)    , optional      :: sorted
   13543             :         logical(LK)             , intent(in)    , optional      :: unique
   13544             :     end subroutine
   13545             : #endif
   13546             : 
   13547             : #if CK2_ENABLED
   13548             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_CK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13549             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13550             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_CK2
   13551             : #endif
   13552             :         use pm_kind, only: CKC => CK2
   13553             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13554             :         complex(CKC)            , intent(in)                    :: pattern
   13555             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   13556             :        !procedure(iseq_D0_D0_CK2)                               :: iseq
   13557             :         procedure(logical(LK))                                  :: iseq
   13558             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13559             :         logical(LK)             , intent(in)    , optional      :: sorted
   13560             :         logical(LK)             , intent(in)    , optional      :: unique
   13561             :     end subroutine
   13562             : 
   13563             : #endif
   13564             : 
   13565             : #if CK1_ENABLED
   13566             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_CK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13567             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13568             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_CK1
   13569             : #endif
   13570             :         use pm_kind, only: CKC => CK1
   13571             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13572             :         complex(CKC)            , intent(in)                    :: pattern
   13573             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   13574             :        !procedure(iseq_D0_D0_CK1)                               :: iseq
   13575             :         procedure(logical(LK))                                  :: iseq
   13576             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13577             :         logical(LK)             , intent(in)    , optional      :: sorted
   13578             :         logical(LK)             , intent(in)    , optional      :: unique
   13579             :     end subroutine
   13580             : #endif
   13581             : 
   13582             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13583             : 
   13584             : #if RK5_ENABLED
   13585             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_RK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13586             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13587             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_RK5
   13588             : #endif
   13589             :         use pm_kind, only: RKC => RK5
   13590             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   13591             :         real(RKC)               , intent(in)                    :: pattern
   13592             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   13593             :        !procedure(iseq_D0_D0_RK5)                               :: iseq
   13594             :         procedure(logical(LK))                                  :: iseq
   13595             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13596             :         logical(LK)             , intent(in)    , optional      :: sorted
   13597             :         logical(LK)             , intent(in)    , optional      :: unique
   13598             :     end subroutine
   13599             : #endif
   13600             : 
   13601             : #if RK4_ENABLED
   13602             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_RK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13603             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13604             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_RK4
   13605             : #endif
   13606             :         use pm_kind, only: RKC => RK4
   13607             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   13608             :         real(RKC)               , intent(in)                    :: pattern
   13609             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   13610             :        !procedure(iseq_D0_D0_RK4)                               :: iseq
   13611             :         procedure(logical(LK))                                  :: iseq
   13612             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13613             :         logical(LK)             , intent(in)    , optional      :: sorted
   13614             :         logical(LK)             , intent(in)    , optional      :: unique
   13615             :     end subroutine
   13616             : #endif
   13617             : 
   13618             : #if RK3_ENABLED
   13619             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_RK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13620             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13621             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_RK3
   13622             : #endif
   13623             :         use pm_kind, only: RKC => RK3
   13624             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   13625             :         real(RKC)               , intent(in)                    :: pattern
   13626             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   13627             :        !procedure(iseq_D0_D0_RK3)                               :: iseq
   13628             :         procedure(logical(LK))                                  :: iseq
   13629             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13630             :         logical(LK)             , intent(in)    , optional      :: sorted
   13631             :         logical(LK)             , intent(in)    , optional      :: unique
   13632             :     end subroutine
   13633             : #endif
   13634             : 
   13635             : #if RK2_ENABLED
   13636             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_RK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13637             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13638             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_RK2
   13639             : #endif
   13640             :         use pm_kind, only: RKC => RK2
   13641             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   13642             :         real(RKC)               , intent(in)                    :: pattern
   13643             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   13644             :        !procedure(iseq_D0_D0_RK2)                               :: iseq
   13645             :         procedure(logical(LK))                                  :: iseq
   13646             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13647             :         logical(LK)             , intent(in)    , optional      :: sorted
   13648             :         logical(LK)             , intent(in)    , optional      :: unique
   13649             :     end subroutine
   13650             : 
   13651             : #endif
   13652             : 
   13653             : #if RK1_ENABLED
   13654             :     module subroutine setReplacedCusComCusIns_D1_D0_D1_RK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13655             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13656             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D0_D1_RK1
   13657             : #endif
   13658             :         use pm_kind, only: RKC => RK1
   13659             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   13660             :         real(RKC)               , intent(in)                    :: pattern
   13661             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   13662             :        !procedure(iseq_D0_D0_RK1)                               :: iseq
   13663             :         procedure(logical(LK))                                  :: iseq
   13664             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13665             :         logical(LK)             , intent(in)    , optional      :: sorted
   13666             :         logical(LK)             , intent(in)    , optional      :: unique
   13667             :     end subroutine
   13668             : #endif
   13669             : 
   13670             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13671             : 
   13672             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13673             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13674             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13675             : 
   13676             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13677             : 
   13678             : #if SK5_ENABLED
   13679             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_SK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13680             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13681             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_SK5
   13682             : #endif
   13683             :         use pm_kind, only: SKC => SK5
   13684             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   13685             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   13686             :         character(*,SKC)        , intent(in)                    :: replacement
   13687             :        !procedure(iseq_D1_D1_SK5)                               :: iseq
   13688             :         procedure(logical(LK))                                  :: iseq
   13689             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13690             :         logical(LK)             , intent(in)    , optional      :: sorted
   13691             :         logical(LK)             , intent(in)    , optional      :: unique
   13692             :     end subroutine
   13693             : #endif
   13694             : 
   13695             : #if SK4_ENABLED
   13696             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_SK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13697             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13698             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_SK4
   13699             : #endif
   13700             :         use pm_kind, only: SKC => SK4
   13701             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   13702             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   13703             :         character(*,SKC)        , intent(in)                    :: replacement
   13704             :        !procedure(iseq_D1_D1_SK4)                               :: iseq
   13705             :         procedure(logical(LK))                                  :: iseq
   13706             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13707             :         logical(LK)             , intent(in)    , optional      :: sorted
   13708             :         logical(LK)             , intent(in)    , optional      :: unique
   13709             :     end subroutine
   13710             : #endif
   13711             : 
   13712             : #if SK3_ENABLED
   13713             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_SK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13714             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13715             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_SK3
   13716             : #endif
   13717             :         use pm_kind, only: SKC => SK3
   13718             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   13719             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   13720             :         character(*,SKC)        , intent(in)                    :: replacement
   13721             :        !procedure(iseq_D1_D1_SK3)                               :: iseq
   13722             :         procedure(logical(LK))                                  :: iseq
   13723             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13724             :         logical(LK)             , intent(in)    , optional      :: sorted
   13725             :         logical(LK)             , intent(in)    , optional      :: unique
   13726             :     end subroutine
   13727             : #endif
   13728             : 
   13729             : #if SK2_ENABLED
   13730             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_SK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13731             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13732             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_SK2
   13733             : #endif
   13734             :         use pm_kind, only: SKC => SK2
   13735             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   13736             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   13737             :         character(*,SKC)        , intent(in)                    :: replacement
   13738             :        !procedure(iseq_D1_D1_SK2)                               :: iseq
   13739             :         procedure(logical(LK))                                  :: iseq
   13740             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13741             :         logical(LK)             , intent(in)    , optional      :: sorted
   13742             :         logical(LK)             , intent(in)    , optional      :: unique
   13743             :     end subroutine
   13744             : 
   13745             : #endif
   13746             : 
   13747             : #if SK1_ENABLED
   13748             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_SK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13749             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13750             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_SK1
   13751             : #endif
   13752             :         use pm_kind, only: SKC => SK1
   13753             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   13754             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   13755             :         character(*,SKC)        , intent(in)                    :: replacement
   13756             :        !procedure(iseq_D1_D1_SK1)                               :: iseq
   13757             :         procedure(logical(LK))                                  :: iseq
   13758             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13759             :         logical(LK)             , intent(in)    , optional      :: sorted
   13760             :         logical(LK)             , intent(in)    , optional      :: unique
   13761             :     end subroutine
   13762             : #endif
   13763             : 
   13764             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13765             : 
   13766             : #if IK5_ENABLED
   13767             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_IK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13768             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13769             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_IK5
   13770             : #endif
   13771             :         use pm_kind, only: IKC => IK5
   13772             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   13773             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   13774             :         integer(IKC)            , intent(in)                    :: replacement
   13775             :        !procedure(iseq_D1_D1_IK5)                               :: iseq
   13776             :         procedure(logical(LK))                                  :: iseq
   13777             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13778             :         logical(LK)             , intent(in)    , optional      :: sorted
   13779             :         logical(LK)             , intent(in)    , optional      :: unique
   13780             :     end subroutine
   13781             : #endif
   13782             : 
   13783             : #if IK4_ENABLED
   13784             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_IK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13785             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13786             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_IK4
   13787             : #endif
   13788             :         use pm_kind, only: IKC => IK4
   13789             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   13790             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   13791             :         integer(IKC)            , intent(in)                    :: replacement
   13792             :        !procedure(iseq_D1_D1_IK4)                               :: iseq
   13793             :         procedure(logical(LK))                                  :: iseq
   13794             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13795             :         logical(LK)             , intent(in)    , optional      :: sorted
   13796             :         logical(LK)             , intent(in)    , optional      :: unique
   13797             :     end subroutine
   13798             : #endif
   13799             : 
   13800             : #if IK3_ENABLED
   13801             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_IK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13802             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13803             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_IK3
   13804             : #endif
   13805             :         use pm_kind, only: IKC => IK3
   13806             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   13807             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   13808             :         integer(IKC)            , intent(in)                    :: replacement
   13809             :        !procedure(iseq_D1_D1_IK3)                               :: iseq
   13810             :         procedure(logical(LK))                                  :: iseq
   13811             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13812             :         logical(LK)             , intent(in)    , optional      :: sorted
   13813             :         logical(LK)             , intent(in)    , optional      :: unique
   13814             :     end subroutine
   13815             : #endif
   13816             : 
   13817             : #if IK2_ENABLED
   13818             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_IK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13819             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13820             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_IK2
   13821             : #endif
   13822             :         use pm_kind, only: IKC => IK2
   13823             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   13824             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   13825             :         integer(IKC)            , intent(in)                    :: replacement
   13826             :        !procedure(iseq_D1_D1_IK2)                               :: iseq
   13827             :         procedure(logical(LK))                                  :: iseq
   13828             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13829             :         logical(LK)             , intent(in)    , optional      :: sorted
   13830             :         logical(LK)             , intent(in)    , optional      :: unique
   13831             :     end subroutine
   13832             : 
   13833             : #endif
   13834             : 
   13835             : #if IK1_ENABLED
   13836             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_IK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13837             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13838             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_IK1
   13839             : #endif
   13840             :         use pm_kind, only: IKC => IK1
   13841             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   13842             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   13843             :         integer(IKC)            , intent(in)                    :: replacement
   13844             :        !procedure(iseq_D1_D1_IK1)                               :: iseq
   13845             :         procedure(logical(LK))                                  :: iseq
   13846             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13847             :         logical(LK)             , intent(in)    , optional      :: sorted
   13848             :         logical(LK)             , intent(in)    , optional      :: unique
   13849             :     end subroutine
   13850             : #endif
   13851             : 
   13852             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13853             : 
   13854             : #if LK5_ENABLED
   13855             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_LK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13856             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13857             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_LK5
   13858             : #endif
   13859             :         use pm_kind, only: LKC => LK5
   13860             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13861             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   13862             :         logical(LKC)            , intent(in)                    :: replacement
   13863             :        !procedure(iseq_D1_D1_LK5)                               :: iseq
   13864             :         procedure(logical(LK))                                  :: iseq
   13865             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13866             :         logical(LK)             , intent(in)    , optional      :: sorted
   13867             :         logical(LK)             , intent(in)    , optional      :: unique
   13868             :     end subroutine
   13869             : #endif
   13870             : 
   13871             : #if LK4_ENABLED
   13872             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_LK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13873             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13874             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_LK4
   13875             : #endif
   13876             :         use pm_kind, only: LKC => LK4
   13877             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13878             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   13879             :         logical(LKC)            , intent(in)                    :: replacement
   13880             :        !procedure(iseq_D1_D1_LK4)                               :: iseq
   13881             :         procedure(logical(LK))                                  :: iseq
   13882             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13883             :         logical(LK)             , intent(in)    , optional      :: sorted
   13884             :         logical(LK)             , intent(in)    , optional      :: unique
   13885             :     end subroutine
   13886             : #endif
   13887             : 
   13888             : #if LK3_ENABLED
   13889             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_LK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13890             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13891             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_LK3
   13892             : #endif
   13893             :         use pm_kind, only: LKC => LK3
   13894             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13895             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   13896             :         logical(LKC)            , intent(in)                    :: replacement
   13897             :        !procedure(iseq_D1_D1_LK3)                               :: iseq
   13898             :         procedure(logical(LK))                                  :: iseq
   13899             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13900             :         logical(LK)             , intent(in)    , optional      :: sorted
   13901             :         logical(LK)             , intent(in)    , optional      :: unique
   13902             :     end subroutine
   13903             : #endif
   13904             : 
   13905             : #if LK2_ENABLED
   13906             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_LK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13907             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13908             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_LK2
   13909             : #endif
   13910             :         use pm_kind, only: LKC => LK2
   13911             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13912             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   13913             :         logical(LKC)            , intent(in)                    :: replacement
   13914             :        !procedure(iseq_D1_D1_LK2)                               :: iseq
   13915             :         procedure(logical(LK))                                  :: iseq
   13916             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13917             :         logical(LK)             , intent(in)    , optional      :: sorted
   13918             :         logical(LK)             , intent(in)    , optional      :: unique
   13919             :     end subroutine
   13920             : 
   13921             : #endif
   13922             : 
   13923             : #if LK1_ENABLED
   13924             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_LK1(array, pattern, replacement, iseq, instance, sorted, unique)
   13925             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13926             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_LK1
   13927             : #endif
   13928             :         use pm_kind, only: LKC => LK1
   13929             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   13930             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   13931             :         logical(LKC)            , intent(in)                    :: replacement
   13932             :        !procedure(iseq_D1_D1_LK1)                               :: iseq
   13933             :         procedure(logical(LK))                                  :: iseq
   13934             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13935             :         logical(LK)             , intent(in)    , optional      :: sorted
   13936             :         logical(LK)             , intent(in)    , optional      :: unique
   13937             :     end subroutine
   13938             : #endif
   13939             : 
   13940             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   13941             : 
   13942             : #if CK5_ENABLED
   13943             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_CK5(array, pattern, replacement, iseq, instance, sorted, unique)
   13944             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13945             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_CK5
   13946             : #endif
   13947             :         use pm_kind, only: CKC => CK5
   13948             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13949             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   13950             :         complex(CKC)            , intent(in)                    :: replacement
   13951             :        !procedure(iseq_D1_D1_CK5)                               :: iseq
   13952             :         procedure(logical(LK))                                  :: iseq
   13953             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13954             :         logical(LK)             , intent(in)    , optional      :: sorted
   13955             :         logical(LK)             , intent(in)    , optional      :: unique
   13956             :     end subroutine
   13957             : #endif
   13958             : 
   13959             : #if CK4_ENABLED
   13960             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_CK4(array, pattern, replacement, iseq, instance, sorted, unique)
   13961             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13962             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_CK4
   13963             : #endif
   13964             :         use pm_kind, only: CKC => CK4
   13965             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13966             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   13967             :         complex(CKC)            , intent(in)                    :: replacement
   13968             :        !procedure(iseq_D1_D1_CK4)                               :: iseq
   13969             :         procedure(logical(LK))                                  :: iseq
   13970             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13971             :         logical(LK)             , intent(in)    , optional      :: sorted
   13972             :         logical(LK)             , intent(in)    , optional      :: unique
   13973             :     end subroutine
   13974             : #endif
   13975             : 
   13976             : #if CK3_ENABLED
   13977             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_CK3(array, pattern, replacement, iseq, instance, sorted, unique)
   13978             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13979             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_CK3
   13980             : #endif
   13981             :         use pm_kind, only: CKC => CK3
   13982             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   13983             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   13984             :         complex(CKC)            , intent(in)                    :: replacement
   13985             :        !procedure(iseq_D1_D1_CK3)                               :: iseq
   13986             :         procedure(logical(LK))                                  :: iseq
   13987             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   13988             :         logical(LK)             , intent(in)    , optional      :: sorted
   13989             :         logical(LK)             , intent(in)    , optional      :: unique
   13990             :     end subroutine
   13991             : #endif
   13992             : 
   13993             : #if CK2_ENABLED
   13994             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_CK2(array, pattern, replacement, iseq, instance, sorted, unique)
   13995             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   13996             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_CK2
   13997             : #endif
   13998             :         use pm_kind, only: CKC => CK2
   13999             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   14000             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   14001             :         complex(CKC)            , intent(in)                    :: replacement
   14002             :        !procedure(iseq_D1_D1_CK2)                               :: iseq
   14003             :         procedure(logical(LK))                                  :: iseq
   14004             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14005             :         logical(LK)             , intent(in)    , optional      :: sorted
   14006             :         logical(LK)             , intent(in)    , optional      :: unique
   14007             :     end subroutine
   14008             : 
   14009             : #endif
   14010             : 
   14011             : #if CK1_ENABLED
   14012             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_CK1(array, pattern, replacement, iseq, instance, sorted, unique)
   14013             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14014             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_CK1
   14015             : #endif
   14016             :         use pm_kind, only: CKC => CK1
   14017             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   14018             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   14019             :         complex(CKC)            , intent(in)                    :: replacement
   14020             :        !procedure(iseq_D1_D1_CK1)                               :: iseq
   14021             :         procedure(logical(LK))                                  :: iseq
   14022             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14023             :         logical(LK)             , intent(in)    , optional      :: sorted
   14024             :         logical(LK)             , intent(in)    , optional      :: unique
   14025             :     end subroutine
   14026             : #endif
   14027             : 
   14028             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14029             : 
   14030             : #if RK5_ENABLED
   14031             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_RK5(array, pattern, replacement, iseq, instance, sorted, unique)
   14032             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14033             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_RK5
   14034             : #endif
   14035             :         use pm_kind, only: RKC => RK5
   14036             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   14037             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   14038             :         real(RKC)               , intent(in)                    :: replacement
   14039             :        !procedure(iseq_D1_D1_RK5)                               :: iseq
   14040             :         procedure(logical(LK))                                  :: iseq
   14041             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14042             :         logical(LK)             , intent(in)    , optional      :: sorted
   14043             :         logical(LK)             , intent(in)    , optional      :: unique
   14044             :     end subroutine
   14045             : #endif
   14046             : 
   14047             : #if RK4_ENABLED
   14048             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_RK4(array, pattern, replacement, iseq, instance, sorted, unique)
   14049             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14050             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_RK4
   14051             : #endif
   14052             :         use pm_kind, only: RKC => RK4
   14053             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   14054             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   14055             :         real(RKC)               , intent(in)                    :: replacement
   14056             :        !procedure(iseq_D1_D1_RK4)                               :: iseq
   14057             :         procedure(logical(LK))                                  :: iseq
   14058             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14059             :         logical(LK)             , intent(in)    , optional      :: sorted
   14060             :         logical(LK)             , intent(in)    , optional      :: unique
   14061             :     end subroutine
   14062             : #endif
   14063             : 
   14064             : #if RK3_ENABLED
   14065             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_RK3(array, pattern, replacement, iseq, instance, sorted, unique)
   14066             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14067             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_RK3
   14068             : #endif
   14069             :         use pm_kind, only: RKC => RK3
   14070             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   14071             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   14072             :         real(RKC)               , intent(in)                    :: replacement
   14073             :        !procedure(iseq_D1_D1_RK3)                               :: iseq
   14074             :         procedure(logical(LK))                                  :: iseq
   14075             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14076             :         logical(LK)             , intent(in)    , optional      :: sorted
   14077             :         logical(LK)             , intent(in)    , optional      :: unique
   14078             :     end subroutine
   14079             : #endif
   14080             : 
   14081             : #if RK2_ENABLED
   14082             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_RK2(array, pattern, replacement, iseq, instance, sorted, unique)
   14083             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14084             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_RK2
   14085             : #endif
   14086             :         use pm_kind, only: RKC => RK2
   14087             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   14088             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   14089             :         real(RKC)               , intent(in)                    :: replacement
   14090             :        !procedure(iseq_D1_D1_RK2)                               :: iseq
   14091             :         procedure(logical(LK))                                  :: iseq
   14092             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14093             :         logical(LK)             , intent(in)    , optional      :: sorted
   14094             :         logical(LK)             , intent(in)    , optional      :: unique
   14095             :     end subroutine
   14096             : 
   14097             : #endif
   14098             : 
   14099             : #if RK1_ENABLED
   14100             :     module subroutine setReplacedCusComCusIns_D1_D1_D0_RK1(array, pattern, replacement, iseq, instance, sorted, unique)
   14101             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14102             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D0_RK1
   14103             : #endif
   14104             :         use pm_kind, only: RKC => RK1
   14105             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   14106             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   14107             :         real(RKC)               , intent(in)                    :: replacement
   14108             :        !procedure(iseq_D1_D1_RK1)                               :: iseq
   14109             :         procedure(logical(LK))                                  :: iseq
   14110             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14111             :         logical(LK)             , intent(in)    , optional      :: sorted
   14112             :         logical(LK)             , intent(in)    , optional      :: unique
   14113             :     end subroutine
   14114             : #endif
   14115             : 
   14116             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14117             : 
   14118             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14119             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14120             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14121             : 
   14122             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14123             : 
   14124             : #if SK5_ENABLED
   14125             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_SK5(array, pattern, replacement, iseq, instance, sorted, unique)
   14126             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14127             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_SK5
   14128             : #endif
   14129             :         use pm_kind, only: SKC => SK5
   14130             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   14131             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   14132             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   14133             :        !procedure(iseq_D1_D1_SK5)                               :: iseq
   14134             :         procedure(logical(LK))                                  :: iseq
   14135             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14136             :         logical(LK)             , intent(in)    , optional      :: sorted
   14137             :         logical(LK)             , intent(in)    , optional      :: unique
   14138             :     end subroutine
   14139             : #endif
   14140             : 
   14141             : #if SK4_ENABLED
   14142             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_SK4(array, pattern, replacement, iseq, instance, sorted, unique)
   14143             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14144             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_SK4
   14145             : #endif
   14146             :         use pm_kind, only: SKC => SK4
   14147             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   14148             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   14149             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   14150             :        !procedure(iseq_D1_D1_SK4)                               :: iseq
   14151             :         procedure(logical(LK))                                  :: iseq
   14152             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14153             :         logical(LK)             , intent(in)    , optional      :: sorted
   14154             :         logical(LK)             , intent(in)    , optional      :: unique
   14155             :     end subroutine
   14156             : #endif
   14157             : 
   14158             : #if SK3_ENABLED
   14159             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_SK3(array, pattern, replacement, iseq, instance, sorted, unique)
   14160             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14161             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_SK3
   14162             : #endif
   14163             :         use pm_kind, only: SKC => SK3
   14164             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   14165             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   14166             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   14167             :        !procedure(iseq_D1_D1_SK3)                               :: iseq
   14168             :         procedure(logical(LK))                                  :: iseq
   14169             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14170             :         logical(LK)             , intent(in)    , optional      :: sorted
   14171             :         logical(LK)             , intent(in)    , optional      :: unique
   14172             :     end subroutine
   14173             : #endif
   14174             : 
   14175             : #if SK2_ENABLED
   14176             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_SK2(array, pattern, replacement, iseq, instance, sorted, unique)
   14177             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14178             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_SK2
   14179             : #endif
   14180             :         use pm_kind, only: SKC => SK2
   14181             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   14182             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   14183             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   14184             :        !procedure(iseq_D1_D1_SK2)                               :: iseq
   14185             :         procedure(logical(LK))                                  :: iseq
   14186             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14187             :         logical(LK)             , intent(in)    , optional      :: sorted
   14188             :         logical(LK)             , intent(in)    , optional      :: unique
   14189             :     end subroutine
   14190             : 
   14191             : #endif
   14192             : 
   14193             : #if SK1_ENABLED
   14194             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_SK1(array, pattern, replacement, iseq, instance, sorted, unique)
   14195             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14196             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_SK1
   14197             : #endif
   14198             :         use pm_kind, only: SKC => SK1
   14199             :         character(*,SKC)        , intent(inout) , allocatable   :: array(:)
   14200             :         character(*,SKC)        , intent(in)    , contiguous    :: pattern(:)
   14201             :         character(*,SKC)        , intent(in)    , contiguous    :: replacement(:)
   14202             :        !procedure(iseq_D1_D1_SK1)                               :: iseq
   14203             :         procedure(logical(LK))                                  :: iseq
   14204             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14205             :         logical(LK)             , intent(in)    , optional      :: sorted
   14206             :         logical(LK)             , intent(in)    , optional      :: unique
   14207             :     end subroutine
   14208             : #endif
   14209             : 
   14210             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14211             : 
   14212             : #if IK5_ENABLED
   14213             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_IK5(array, pattern, replacement, iseq, instance, sorted, unique)
   14214             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14215             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_IK5
   14216             : #endif
   14217             :         use pm_kind, only: IKC => IK5
   14218             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   14219             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   14220             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   14221             :        !procedure(iseq_D1_D1_IK5)                               :: iseq
   14222             :         procedure(logical(LK))                                  :: iseq
   14223             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14224             :         logical(LK)             , intent(in)    , optional      :: sorted
   14225             :         logical(LK)             , intent(in)    , optional      :: unique
   14226             :     end subroutine
   14227             : #endif
   14228             : 
   14229             : #if IK4_ENABLED
   14230             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_IK4(array, pattern, replacement, iseq, instance, sorted, unique)
   14231             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14232             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_IK4
   14233             : #endif
   14234             :         use pm_kind, only: IKC => IK4
   14235             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   14236             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   14237             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   14238             :        !procedure(iseq_D1_D1_IK4)                               :: iseq
   14239             :         procedure(logical(LK))                                  :: iseq
   14240             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14241             :         logical(LK)             , intent(in)    , optional      :: sorted
   14242             :         logical(LK)             , intent(in)    , optional      :: unique
   14243             :     end subroutine
   14244             : #endif
   14245             : 
   14246             : #if IK3_ENABLED
   14247             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_IK3(array, pattern, replacement, iseq, instance, sorted, unique)
   14248             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14249             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_IK3
   14250             : #endif
   14251             :         use pm_kind, only: IKC => IK3
   14252             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   14253             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   14254             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   14255             :        !procedure(iseq_D1_D1_IK3)                               :: iseq
   14256             :         procedure(logical(LK))                                  :: iseq
   14257             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14258             :         logical(LK)             , intent(in)    , optional      :: sorted
   14259             :         logical(LK)             , intent(in)    , optional      :: unique
   14260             :     end subroutine
   14261             : #endif
   14262             : 
   14263             : #if IK2_ENABLED
   14264             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_IK2(array, pattern, replacement, iseq, instance, sorted, unique)
   14265             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14266             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_IK2
   14267             : #endif
   14268             :         use pm_kind, only: IKC => IK2
   14269             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   14270             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   14271             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   14272             :        !procedure(iseq_D1_D1_IK2)                               :: iseq
   14273             :         procedure(logical(LK))                                  :: iseq
   14274             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14275             :         logical(LK)             , intent(in)    , optional      :: sorted
   14276             :         logical(LK)             , intent(in)    , optional      :: unique
   14277             :     end subroutine
   14278             : 
   14279             : #endif
   14280             : 
   14281             : #if IK1_ENABLED
   14282             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_IK1(array, pattern, replacement, iseq, instance, sorted, unique)
   14283             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14284             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_IK1
   14285             : #endif
   14286             :         use pm_kind, only: IKC => IK1
   14287             :         integer(IKC)            , intent(inout) , allocatable   :: array(:)
   14288             :         integer(IKC)            , intent(in)    , contiguous    :: pattern(:)
   14289             :         integer(IKC)            , intent(in)    , contiguous    :: replacement(:)
   14290             :        !procedure(iseq_D1_D1_IK1)                               :: iseq
   14291             :         procedure(logical(LK))                                  :: iseq
   14292             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14293             :         logical(LK)             , intent(in)    , optional      :: sorted
   14294             :         logical(LK)             , intent(in)    , optional      :: unique
   14295             :     end subroutine
   14296             : #endif
   14297             : 
   14298             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14299             : 
   14300             : #if LK5_ENABLED
   14301             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_LK5(array, pattern, replacement, iseq, instance, sorted, unique)
   14302             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14303             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_LK5
   14304             : #endif
   14305             :         use pm_kind, only: LKC => LK5
   14306             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   14307             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   14308             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   14309             :        !procedure(iseq_D1_D1_LK5)                               :: iseq
   14310             :         procedure(logical(LK))                                  :: iseq
   14311             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14312             :         logical(LK)             , intent(in)    , optional      :: sorted
   14313             :         logical(LK)             , intent(in)    , optional      :: unique
   14314             :     end subroutine
   14315             : #endif
   14316             : 
   14317             : #if LK4_ENABLED
   14318             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_LK4(array, pattern, replacement, iseq, instance, sorted, unique)
   14319             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14320             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_LK4
   14321             : #endif
   14322             :         use pm_kind, only: LKC => LK4
   14323             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   14324             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   14325             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   14326             :        !procedure(iseq_D1_D1_LK4)                               :: iseq
   14327             :         procedure(logical(LK))                                  :: iseq
   14328             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14329             :         logical(LK)             , intent(in)    , optional      :: sorted
   14330             :         logical(LK)             , intent(in)    , optional      :: unique
   14331             :     end subroutine
   14332             : #endif
   14333             : 
   14334             : #if LK3_ENABLED
   14335             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_LK3(array, pattern, replacement, iseq, instance, sorted, unique)
   14336             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14337             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_LK3
   14338             : #endif
   14339             :         use pm_kind, only: LKC => LK3
   14340             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   14341             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   14342             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   14343             :        !procedure(iseq_D1_D1_LK3)                               :: iseq
   14344             :         procedure(logical(LK))                                  :: iseq
   14345             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14346             :         logical(LK)             , intent(in)    , optional      :: sorted
   14347             :         logical(LK)             , intent(in)    , optional      :: unique
   14348             :     end subroutine
   14349             : #endif
   14350             : 
   14351             : #if LK2_ENABLED
   14352             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_LK2(array, pattern, replacement, iseq, instance, sorted, unique)
   14353             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14354             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_LK2
   14355             : #endif
   14356             :         use pm_kind, only: LKC => LK2
   14357             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   14358             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   14359             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   14360             :        !procedure(iseq_D1_D1_LK2)                               :: iseq
   14361             :         procedure(logical(LK))                                  :: iseq
   14362             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14363             :         logical(LK)             , intent(in)    , optional      :: sorted
   14364             :         logical(LK)             , intent(in)    , optional      :: unique
   14365             :     end subroutine
   14366             : 
   14367             : #endif
   14368             : 
   14369             : #if LK1_ENABLED
   14370             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_LK1(array, pattern, replacement, iseq, instance, sorted, unique)
   14371             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14372             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_LK1
   14373             : #endif
   14374             :         use pm_kind, only: LKC => LK1
   14375             :         logical(LKC)            , intent(inout) , allocatable   :: array(:)
   14376             :         logical(LKC)            , intent(in)    , contiguous    :: pattern(:)
   14377             :         logical(LKC)            , intent(in)    , contiguous    :: replacement(:)
   14378             :        !procedure(iseq_D1_D1_LK1)                               :: iseq
   14379             :         procedure(logical(LK))                                  :: iseq
   14380             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14381             :         logical(LK)             , intent(in)    , optional      :: sorted
   14382             :         logical(LK)             , intent(in)    , optional      :: unique
   14383             :     end subroutine
   14384             : #endif
   14385             : 
   14386             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14387             : 
   14388             : #if CK5_ENABLED
   14389             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_CK5(array, pattern, replacement, iseq, instance, sorted, unique)
   14390             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14391             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_CK5
   14392             : #endif
   14393             :         use pm_kind, only: CKC => CK5
   14394             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   14395             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   14396             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   14397             :        !procedure(iseq_D1_D1_CK5)                               :: iseq
   14398             :         procedure(logical(LK))                                  :: iseq
   14399             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14400             :         logical(LK)             , intent(in)    , optional      :: sorted
   14401             :         logical(LK)             , intent(in)    , optional      :: unique
   14402             :     end subroutine
   14403             : #endif
   14404             : 
   14405             : #if CK4_ENABLED
   14406             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_CK4(array, pattern, replacement, iseq, instance, sorted, unique)
   14407             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14408             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_CK4
   14409             : #endif
   14410             :         use pm_kind, only: CKC => CK4
   14411             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   14412             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   14413             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   14414             :        !procedure(iseq_D1_D1_CK4)                               :: iseq
   14415             :         procedure(logical(LK))                                  :: iseq
   14416             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14417             :         logical(LK)             , intent(in)    , optional      :: sorted
   14418             :         logical(LK)             , intent(in)    , optional      :: unique
   14419             :     end subroutine
   14420             : #endif
   14421             : 
   14422             : #if CK3_ENABLED
   14423             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_CK3(array, pattern, replacement, iseq, instance, sorted, unique)
   14424             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14425             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_CK3
   14426             : #endif
   14427             :         use pm_kind, only: CKC => CK3
   14428             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   14429             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   14430             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   14431             :        !procedure(iseq_D1_D1_CK3)                               :: iseq
   14432             :         procedure(logical(LK))                                  :: iseq
   14433             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14434             :         logical(LK)             , intent(in)    , optional      :: sorted
   14435             :         logical(LK)             , intent(in)    , optional      :: unique
   14436             :     end subroutine
   14437             : #endif
   14438             : 
   14439             : #if CK2_ENABLED
   14440             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_CK2(array, pattern, replacement, iseq, instance, sorted, unique)
   14441             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14442             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_CK2
   14443             : #endif
   14444             :         use pm_kind, only: CKC => CK2
   14445             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   14446             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   14447             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   14448             :        !procedure(iseq_D1_D1_CK2)                               :: iseq
   14449             :         procedure(logical(LK))                                  :: iseq
   14450             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14451             :         logical(LK)             , intent(in)    , optional      :: sorted
   14452             :         logical(LK)             , intent(in)    , optional      :: unique
   14453             :     end subroutine
   14454             : 
   14455             : #endif
   14456             : 
   14457             : #if CK1_ENABLED
   14458             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_CK1(array, pattern, replacement, iseq, instance, sorted, unique)
   14459             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14460             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_CK1
   14461             : #endif
   14462             :         use pm_kind, only: CKC => CK1
   14463             :         complex(CKC)            , intent(inout) , allocatable   :: array(:)
   14464             :         complex(CKC)            , intent(in)    , contiguous    :: pattern(:)
   14465             :         complex(CKC)            , intent(in)    , contiguous    :: replacement(:)
   14466             :        !procedure(iseq_D1_D1_CK1)                               :: iseq
   14467             :         procedure(logical(LK))                                  :: iseq
   14468             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14469             :         logical(LK)             , intent(in)    , optional      :: sorted
   14470             :         logical(LK)             , intent(in)    , optional      :: unique
   14471             :     end subroutine
   14472             : #endif
   14473             : 
   14474             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14475             : 
   14476             : #if RK5_ENABLED
   14477             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_RK5(array, pattern, replacement, iseq, instance, sorted, unique)
   14478             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14479             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_RK5
   14480             : #endif
   14481             :         use pm_kind, only: RKC => RK5
   14482             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   14483             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   14484             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   14485             :        !procedure(iseq_D1_D1_RK5)                               :: iseq
   14486             :         procedure(logical(LK))                                  :: iseq
   14487             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14488             :         logical(LK)             , intent(in)    , optional      :: sorted
   14489             :         logical(LK)             , intent(in)    , optional      :: unique
   14490             :     end subroutine
   14491             : #endif
   14492             : 
   14493             : #if RK4_ENABLED
   14494             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_RK4(array, pattern, replacement, iseq, instance, sorted, unique)
   14495             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14496             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_RK4
   14497             : #endif
   14498             :         use pm_kind, only: RKC => RK4
   14499             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   14500             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   14501             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   14502             :        !procedure(iseq_D1_D1_RK4)                               :: iseq
   14503             :         procedure(logical(LK))                                  :: iseq
   14504             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14505             :         logical(LK)             , intent(in)    , optional      :: sorted
   14506             :         logical(LK)             , intent(in)    , optional      :: unique
   14507             :     end subroutine
   14508             : #endif
   14509             : 
   14510             : #if RK3_ENABLED
   14511             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_RK3(array, pattern, replacement, iseq, instance, sorted, unique)
   14512             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14513             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_RK3
   14514             : #endif
   14515             :         use pm_kind, only: RKC => RK3
   14516             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   14517             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   14518             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   14519             :        !procedure(iseq_D1_D1_RK3)                               :: iseq
   14520             :         procedure(logical(LK))                                  :: iseq
   14521             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14522             :         logical(LK)             , intent(in)    , optional      :: sorted
   14523             :         logical(LK)             , intent(in)    , optional      :: unique
   14524             :     end subroutine
   14525             : #endif
   14526             : 
   14527             : #if RK2_ENABLED
   14528             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_RK2(array, pattern, replacement, iseq, instance, sorted, unique)
   14529             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14530             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_RK2
   14531             : #endif
   14532             :         use pm_kind, only: RKC => RK2
   14533             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   14534             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   14535             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   14536             :        !procedure(iseq_D1_D1_RK2)                               :: iseq
   14537             :         procedure(logical(LK))                                  :: iseq
   14538             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14539             :         logical(LK)             , intent(in)    , optional      :: sorted
   14540             :         logical(LK)             , intent(in)    , optional      :: unique
   14541             :     end subroutine
   14542             : 
   14543             : #endif
   14544             : 
   14545             : #if RK1_ENABLED
   14546             :     module subroutine setReplacedCusComCusIns_D1_D1_D1_RK1(array, pattern, replacement, iseq, instance, sorted, unique)
   14547             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14548             :         !DEC$ ATTRIBUTES DLLEXPORT :: setReplacedCusComCusIns_D1_D1_D1_RK1
   14549             : #endif
   14550             :         use pm_kind, only: RKC => RK1
   14551             :         real(RKC)               , intent(inout) , allocatable   :: array(:)
   14552             :         real(RKC)               , intent(in)    , contiguous    :: pattern(:)
   14553             :         real(RKC)               , intent(in)    , contiguous    :: replacement(:)
   14554             :        !procedure(iseq_D1_D1_RK1)                               :: iseq
   14555             :         procedure(logical(LK))                                  :: iseq
   14556             :         integer(IK)             , intent(in)    , contiguous    :: instance(:)
   14557             :         logical(LK)             , intent(in)    , optional      :: sorted
   14558             :         logical(LK)             , intent(in)    , optional      :: unique
   14559             :     end subroutine
   14560             : #endif
   14561             : 
   14562             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14563             : 
   14564             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14565             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14566             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14567             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14568             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14569             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14570             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14571             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14572             :     !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14573             : 
   14574             :     end interface
   14575             : 
   14576             : !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14577             : 
   14578             : contains
   14579             : 
   14580             : !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14581             : 
   14582             :     !>  \brief
   14583             :     !>  \legacy
   14584             :     !>  Generate and return a copy of the input `array` where all instances of the input `pattern` in it are replaced with the input `replacement`.<br>
   14585             :     !>
   14586             :     !>  \param[in]  array       :   The input scalar `character` of default kind \SK.<br>
   14587             :     !>  \param[in]  pattern     :   The input scalar the same type and kind as the input `array` representing the pattern to be searched within `array`.<br>
   14588             :     !>  \param[in]  replacement :   The input scalar the same type and kind as the input `array` representing the replacement for instances of `pattern` in `array`.<br>
   14589             :     !>
   14590             :     !>  \return
   14591             :     !>  `arrayNew`              :   The output copy of the input `array` where all instances of the input `pattern` in it are replaced with the input `replacement`.<br>
   14592             :     !>
   14593             :     !>  \warning
   14594             :     !>  This procedure is solely provided for benchmarking purposes to compare the performance difference between
   14595             :     !>  a naive recursive allocation method of replacement and the optimized method implemented under the generic
   14596             :     !>  interfaces in [getReplaced](@ref pm_arrayReplace::getReplaced) and [setReplaced](@ref pm_arrayReplace::setReplaced).<br>
   14597             :     !>
   14598             :     !>  \pure
   14599             :     !>
   14600             :     !>  \recursive
   14601             :     !>
   14602             :     !>  \see
   14603             :     !>  [getReplaced](@ref pm_arrayReplace::getReplaced)<br>
   14604             :     !>  [setReplaced](@ref pm_arrayReplace::setReplaced)<br>
   14605             :     !>
   14606             :     !>  [test_pm_arrayReplace](@ref test_pm_arrayReplace)
   14607             :     !>
   14608             :     !>  \finmain
   14609             :     !>
   14610             :     !>  \author
   14611             :     !>  \AmirShahmoradi, September 1, 2017, 12:00 AM, Institute for Computational Engineering and Sciences (ICES), The University of Texas at Austin
   14612           6 :     pure recursive function getReplaced_recurs_alloc(array, pattern, replacement) result(arrayNew)
   14613             : #if __INTEL_COMPILER && DLL_ENABLED && (_WIN32 || _WIN64)
   14614             :         !DEC$ ATTRIBUTES DLLEXPORT :: getReplaced_recurs_alloc
   14615             : #endif
   14616             :         use pm_kind, only: IK
   14617             :         implicit none
   14618             :         character(*, SK), intent(in)  :: array, pattern, replacement
   14619             :         character(:, SK), allocatable :: arrayNew
   14620             :         integer(IK)                   :: i, lenArray, lenPattern
   14621           6 :         lenArray = len(array)
   14622           6 :         lenPattern = len(pattern)
   14623           6 :         if (lenArray == 0_IK .or. lenPattern == 0_IK) then
   14624           1 :             arrayNew = ""
   14625           1 :             return
   14626           5 :         elseif (lenArray < lenPattern) then
   14627           1 :             arrayNew = array
   14628           1 :             return
   14629             :         end if
   14630             :         i = 1_IK
   14631           6 :         do
   14632          10 :             if (array(i:i+lenPattern-1) == pattern) then
   14633           3 :                 arrayNew = array(1:i-1) // replacement // getReplaced_recurs_alloc(array(i+lenPattern:lenArray), pattern, replacement)
   14634           3 :                 exit
   14635             :             end if
   14636           7 :             if (i+lenPattern > lenArray) then
   14637           1 :                 arrayNew = array
   14638             :                 exit
   14639             :             end if
   14640           6 :             i = i + 1_IK
   14641             :             cycle
   14642             :         end do
   14643          12 :     end function
   14644             : 
   14645             : !%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
   14646             : 
   14647             : end module pm_arrayReplace ! LCOV_EXCL_LINE

ParaMonte: Parallel Monte Carlo and Machine Learning Library 
The Computational Data Science Lab
© Copyright 2012 - 2024