diff --git a/src/STEPToXSection.cpp b/src/STEPToXSection.cpp index 33ee488..e9b9681 100644 --- a/src/STEPToXSection.cpp +++ b/src/STEPToXSection.cpp @@ -1145,7 +1145,7 @@ auto getSelectedSolids(const std::vector& namedSolids, const std::ve else { try { int index{std::stoi(sel)}; - if (index < 1 || index > namedSolids.size()) throw std::logic_error{std::string{"Index out of range: "} + sel}; + if (index < 1 || static_cast(index) > namedSolids.size()) throw std::logic_error{std::string{"Index out of range: "} + sel}; builder.Add(compound, namedSolids[index - 1].solid); } catch (const std::invalid_argument&) {