Skip to content
Snippets Groups Projects
Commit 828a604e authored by Michael Wedel's avatar Michael Wedel
Browse files

Refs #14121. Fixing CrystalSystemMap on RHEL6.

parent 3b7267c6
No related branches found
No related tags found
No related merge requests found
...@@ -85,10 +85,6 @@ typedef boost::shared_ptr<PointGroup> PointGroup_sptr; ...@@ -85,10 +85,6 @@ typedef boost::shared_ptr<PointGroup> PointGroup_sptr;
MANTID_GEOMETRY_DLL std::vector<PointGroup_sptr> getAllPointGroups(); MANTID_GEOMETRY_DLL std::vector<PointGroup_sptr> getAllPointGroups();
typedef std::multimap<PointGroup::CrystalSystem, PointGroup_sptr>
PointGroupCrystalSystemMap;
MANTID_GEOMETRY_DLL PointGroupCrystalSystemMap getPointGroupsByCrystalSystem();
MANTID_GEOMETRY_DLL MANTID_GEOMETRY_DLL
std::string std::string
getCrystalSystemAsString(const PointGroup::CrystalSystem &crystalSystem); getCrystalSystemAsString(const PointGroup::CrystalSystem &crystalSystem);
...@@ -105,6 +101,18 @@ MANTID_GEOMETRY_DLL ...@@ -105,6 +101,18 @@ MANTID_GEOMETRY_DLL
PointGroup::LatticeSystem PointGroup::LatticeSystem
getLatticeSystemFromString(const std::string &latticeSystem); getLatticeSystemFromString(const std::string &latticeSystem);
/// This is necessary to make the map work with older compilers. Can be removed
/// when GCC 4.4 is not used anymore.
struct MANTID_GEOMETRY_DLL CrystalSystemComparator {
bool operator()(const PointGroup::CrystalSystem &lhs,
const PointGroup::CrystalSystem &rhs);
};
typedef std::multimap<PointGroup::CrystalSystem, PointGroup_sptr,
CrystalSystemComparator> PointGroupCrystalSystemMap;
MANTID_GEOMETRY_DLL PointGroupCrystalSystemMap getPointGroupsByCrystalSystem();
} // namespace Mantid } // namespace Mantid
} // namespace Geometry } // namespace Geometry
......
...@@ -327,5 +327,10 @@ getLatticeSystemFromString(const std::string &latticeSystem) { ...@@ -327,5 +327,10 @@ getLatticeSystemFromString(const std::string &latticeSystem) {
} }
} }
bool CrystalSystemComparator::operator()(const PointGroup::CrystalSystem &lhs,
const PointGroup::CrystalSystem &rhs) {
return static_cast<int>(lhs) < static_cast<int>(rhs);
}
} // namespace Mantid } // namespace Mantid
} // namespace Geometry } // namespace Geometry
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment