Skip to content

Commit

Permalink
update use of DefaultComparator to silence new deprecation warning fr…
Browse files Browse the repository at this point in the history
…om Sort module. Fix OpenReaderLockingDefault flags to avoid deprecation warning for 2.2. Setup file structure for other deprecation warnings added in 2.2 (Bears-R-Us#3607)

Signed-off-by: Jeremiah Corrado <jeremiah.corrado@hpe.com>
  • Loading branch information
jeremiah-corrado authored Aug 2, 2024
1 parent a4be804 commit dbb6612
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 5 deletions.
10 changes: 7 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -374,11 +374,15 @@ ifeq ($(shell expr $(CHPL_MINOR) \= 0),1)
ARKOUDA_COMPAT_MODULES += -M $(ARKOUDA_SOURCE_DIR)/compat/eq-20
endif

ifeq ($(shell expr $(CHPL_MINOR) \> 0),1)
ARKOUDA_COMPAT_MODULES += -M $(ARKOUDA_SOURCE_DIR)/compat/ge-21
ifeq ($(shell expr $(CHPL_MINOR) \= 1),1)
ARKOUDA_COMPAT_MODULES += -M $(ARKOUDA_SOURCE_DIR)/compat/eq-21
endif

ifeq ($(shell expr $(CHPL_MINOR) \>= 0),1)
ifeq ($(shell expr $(CHPL_MINOR) \>= 2),1)
ARKOUDA_COMPAT_MODULES += -M $(ARKOUDA_SOURCE_DIR)/compat/ge-22
endif

ifeq ($(shell expr $(CHPL_MINOR) \<= 1),1)
ARKOUDA_RW_DEFAULT_FLAG := -sOpenReaderLockingDefault=false -sOpenWriterLockingDefault=false
endif

Expand Down
2 changes: 1 addition & 1 deletion src/ArgSortMsg.chpl
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ module ArgSortMsg
private config const logChannel = ServerConfig.logChannel;
const asLogger = new Logger(logLevel, logChannel);

proc dynamicTwoArrayRadixSort(ref Data:[], comparator:?rec=defaultComparator) {
proc dynamicTwoArrayRadixSort(ref Data:[], comparator:?rec=new DefaultComparator()) {
if Data._instance.isDefaultRectangular() {
Sort.TwoArrayRadixSort.twoArrayRadixSort(Data, comparator);
} else {
Expand Down
2 changes: 1 addition & 1 deletion src/SegStringSort.chpl
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ module SegStringSort {
record StringIntComparator {
proc keyPart((a0,_): (string, int), in i: int) {
// Just run the default comparator on the string
return Sort.defaultComparator.keyPart(a0, i);
return (new DefaultComparator()).keyPart(a0, i);
}
}

Expand Down
File renamed without changes.
1 change: 1 addition & 0 deletions src/compat/ge-22/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
!.gitignore

0 comments on commit dbb6612

Please sign in to comment.