diff --git a/Framework/Geometry/src/Instrument.cpp b/Framework/Geometry/src/Instrument.cpp index 2202bdc38a7ded66ca40ab61a65e3cc6ac2e419c..e9f4cbbe45308fba02cd6de7b1359982c64fc99f 100644 --- a/Framework/Geometry/src/Instrument.cpp +++ b/Framework/Geometry/src/Instrument.cpp @@ -742,7 +742,7 @@ void Instrument::markAsDetectorIncomplete(const IDetector *det) { void Instrument::markAsDetectorFinalize() { // Detectors (even when different objects) are NOT allowed to have duplicate // ids. This method establishes the presence of duplicates. - std::stable_sort(m_detectorCache.begin(), m_detectorCache.end(), + std::sort(m_detectorCache.begin(), m_detectorCache.end(), [](const std::tuple<detid_t, IDetector_const_sptr, bool> &a, const std::tuple<detid_t, IDetector_const_sptr, bool> &b) -> bool { return std::get<0>(a) < std::get<0>(b); });