Skip to content

Commit

Permalink
Trade: yup, it was libc++.
Browse files Browse the repository at this point in the history
Not sure, but maybe calling `compare(a, a)` inside `std::sort()` isn't
the best plan for having the sorting done fast??
  • Loading branch information
mosra committed Nov 27, 2021
1 parent 372e60d commit 491751b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Magnum/Trade/MaterialData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,8 @@ MaterialData::MaterialData(const MaterialTypes types, Containers::Array<Material
Additionally an *extra paranoid* check for shitty STL
implementations that might call this comparator with both
arguments the same (in which case the assert would fire,
which is undesirable). */
which is undesirable). Apparently libc++ is responsible for
such atrocities. */
CORRADE_ASSERT(&a == &b || a.name() != b.name(),
"Trade::MaterialData: duplicate attribute" << a.name(), false);
return a.name() < b.name();
Expand Down

0 comments on commit 491751b

Please sign in to comment.