Skip to content

Commit d3ee48f

Browse files
authored
Merge pull request #111 from rest-for-physics/jgalan_hits_iterator_fix
TRestDetectorHitsEvent::Sort disabled for MacOs
2 parents 360f43a + 2a39606 commit d3ee48f

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Diff for: src/TRestDetectorHitsEvent.cxx

+5
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,7 @@ void TRestDetectorHitsEvent::Initialize() {
137137

138138
void TRestDetectorHitsEvent::Sort(bool(compareCondition)(const TRestHits::iterator& hit1,
139139
const TRestHits::iterator& hit2)) {
140+
#ifndef __APPLE__
140141
if (compareCondition == 0) {
141142
// default sort logic: z from smaller to greater
142143
std::sort(fHits->begin(), fHits->end(),
@@ -146,6 +147,10 @@ void TRestDetectorHitsEvent::Sort(bool(compareCondition)(const TRestHits::iterat
146147
} else {
147148
std::sort(fHits->begin(), fHits->end(), compareCondition);
148149
}
150+
#else
151+
std::cout << "TRestDetectorHitsEvent::Sort is not implemented on MacOs!!" << std::endl;
152+
std::cout << "This method implementation should be reviewed for proper operation in Mac" << std::endl;
153+
#endif
149154
}
150155

151156
void TRestDetectorHitsEvent::Shuffle(int NLoop) {

0 commit comments

Comments
 (0)