Skip to content

Commit 799ce0d

Browse files
committed
appended ALT_NAME of bitsets to IRSC ALT_NAME
1 parent b482534 commit 799ce0d

4 files changed

+16
-12
lines changed

Diff for: src/stdlib_sorting.fypp

+5-4
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@
99
#! For better code reuse in fypp, make lists that contain the input types,
1010
#! with each having output types and a separate name prefix for subroutines
1111
#! This approach allows us to have the same code for all input types.
12-
#:set IRSC_TYPES_ALT_NAME = INT_TYPES_ALT_NAME + REAL_TYPES_ALT_NAME + STRING_TYPES_ALT_NAME + CHAR_TYPES_ALT_NAME
12+
#:set IRSCB_TYPES_ALT_NAME = INT_TYPES_ALT_NAME + REAL_TYPES_ALT_NAME + STRING_TYPES_ALT_NAME + CHAR_TYPES_ALT_NAME &
13+
& + BITSET_TYPES_ALT_NAME
1314

1415
!! Licensing:
1516
!!
@@ -414,7 +415,7 @@ module stdlib_sorting
414415
!! sorted data, having O(N) performance on uniformly non-increasing or
415416
!! non-decreasing data.
416417

417-
#:for t1, t2, name1 in IRSC_TYPES_ALT_NAME
418+
#:for t1, t2, name1 in IRSCB_TYPES_ALT_NAME
418419
module subroutine ${name1}$_ord_sort( array, work, reverse )
419420
!! Version: experimental
420421
!!
@@ -480,7 +481,7 @@ module stdlib_sorting
480481
!! on the `introsort` of David Musser.
481482
!! ([Specification](../page/specs/stdlib_sorting.html#sort-sorts-an-input-array))
482483

483-
#:for t1, t2, name1 in IRSC_TYPES_ALT_NAME
484+
#:for t1, t2, name1 in IRSCB_TYPES_ALT_NAME
484485
pure module subroutine ${name1}$_sort( array, reverse )
485486
!! Version: experimental
486487
!!
@@ -511,7 +512,7 @@ module stdlib_sorting
511512
!! non-decreasing sort, but if the optional argument `REVERSE` is present
512513
!! with a value of `.TRUE.` the indices correspond to a non-increasing sort.
513514

514-
#:for t1, t2, name1 in IRSC_TYPES_ALT_NAME
515+
#:for t1, t2, name1 in IRSCB_TYPES_ALT_NAME
515516
module subroutine ${name1}$_sort_index( array, index, work, iwork, &
516517
reverse )
517518
!! Version: experimental

Diff for: src/stdlib_sorting_ord_sort.fypp

+4-3
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
#! For better code reuse in fypp, make lists that contain the input types,
99
#! with each having output types and a separate name prefix for subroutines
1010
#! This approach allows us to have the same code for all input types.
11-
#:set IRSC_TYPES_ALT_NAME = INT_TYPES_ALT_NAME + REAL_TYPES_ALT_NAME + STRING_TYPES_ALT_NAME + CHAR_TYPES_ALT_NAME
11+
#:set IRSCB_TYPES_ALT_NAME = INT_TYPES_ALT_NAME + REAL_TYPES_ALT_NAME + STRING_TYPES_ALT_NAME + CHAR_TYPES_ALT_NAME &
12+
& + BITSET_TYPES_ALT_NAME
1213

1314
#:set SIGN_NAME = ["increase", "decrease"]
1415
#:set SIGN_TYPE = [">", "<"]
@@ -70,7 +71,7 @@ submodule(stdlib_sorting) stdlib_sorting_ord_sort
7071

7172
contains
7273

73-
#:for t1, t2, t3, name1 in IRSC_TYPES_ALT_NAME
74+
#:for t1, t2, t3, name1 in IRSCB_TYPES_ALT_NAME
7475
module subroutine ${name1}$_ord_sort( array, work, reverse )
7576
${t1}$, intent(inout) :: array(0:)
7677
${t3}$, intent(out), optional :: work(0:)
@@ -86,7 +87,7 @@ contains
8687
#:endfor
8788

8889
#:for sname, signt, signoppt in SIGN_NAME_TYPE
89-
#:for t1, t2, t3, name1 in IRSC_TYPES_ALT_NAME
90+
#:for t1, t2, t3, name1 in IRSCB_TYPES_ALT_NAME
9091

9192
subroutine ${name1}$_${sname}$_ord_sort( array, work )
9293
! A translation to Fortran 2008, of the `"Rust" sort` algorithm found in

Diff for: src/stdlib_sorting_sort.fypp

+4-3
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
#! For better code reuse in fypp, make lists that contain the input types,
99
#! with each having output types and a separate name prefix for subroutines
1010
#! This approach allows us to have the same code for all input types.
11-
#:set IRSC_TYPES_ALT_NAME = INT_TYPES_ALT_NAME + REAL_TYPES_ALT_NAME + STRING_TYPES_ALT_NAME + CHAR_TYPES_ALT_NAME
11+
#:set IRSCB_TYPES_ALT_NAME = INT_TYPES_ALT_NAME + REAL_TYPES_ALT_NAME + STRING_TYPES_ALT_NAME + CHAR_TYPES_ALT_NAME &
12+
& + BITSET_TYPES_ALT_NAME
1213

1314
#:set SIGN_NAME = ["increase", "decrease"]
1415
#:set SIGN_TYPE = [">", "<"]
@@ -74,7 +75,7 @@ submodule(stdlib_sorting) stdlib_sorting_sort
7475

7576
contains
7677

77-
#:for t1, t2, name1 in IRSC_TYPES_ALT_NAME
78+
#:for t1, t2, name1 in IRSCB_TYPES_ALT_NAME
7879
pure module subroutine ${name1}$_sort( array, reverse )
7980
${t1}$, intent(inout) :: array(0:)
8081
logical, intent(in), optional :: reverse
@@ -88,7 +89,7 @@ contains
8889
#:endfor
8990

9091
#:for sname, signt, signoppt in SIGN_NAME_TYPE
91-
#:for t1, t2, name1 in IRSC_TYPES_ALT_NAME
92+
#:for t1, t2, name1 in IRSCB_TYPES_ALT_NAME
9293

9394
pure subroutine ${name1}$_${sname}$_sort( array )
9495
! `${name1}$_${sname}$_sort( array )` sorts the input `ARRAY` of type `${t1}$`

Diff for: src/stdlib_sorting_sort_index.fypp

+3-2
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
#! For better code reuse in fypp, make lists that contain the input types,
99
#! with each having output types and a separate name prefix for subroutines
1010
#! This approach allows us to have the same code for all input types.
11-
#:set IRSC_TYPES_ALT_NAME = INT_TYPES_ALT_NAME + REAL_TYPES_ALT_NAME + STRING_TYPES_ALT_NAME + CHAR_TYPES_ALT_NAME
11+
#:set IRSCB_TYPES_ALT_NAME = INT_TYPES_ALT_NAME + REAL_TYPES_ALT_NAME + STRING_TYPES_ALT_NAME + CHAR_TYPES_ALT_NAME &
12+
& + BITSET_TYPES_ALT_NAME
1213

1314
!! Licensing:
1415
!!
@@ -65,7 +66,7 @@ submodule(stdlib_sorting) stdlib_sorting_sort_index
6566

6667
contains
6768

68-
#:for t1, t2, t3, name1 in IRSC_TYPES_ALT_NAME
69+
#:for t1, t2, t3, name1 in IRSCB_TYPES_ALT_NAME
6970

7071
module subroutine ${name1}$_sort_index( array, index, work, iwork, reverse )
7172
! A modification of `${name1}$_ord_sort` to return an array of indices that

0 commit comments

Comments
 (0)