summaryrefslogtreecommitdiff
path: root/src/company_manager_face.h
diff options
context:
space:
mode:
authorPatric Stout <truebrain@openttd.org>2021-03-03 13:12:29 +0100
committerGitHub <noreply@github.com>2021-03-03 12:12:29 +0000
commit0243ae46547631c72e826ef28caae0637e7723dd (patch)
treea67b055063a09e4636280496cc428c0d4269ea7d /src/company_manager_face.h
parent937d60f239641ee65580dacf1de55bb3d14860f3 (diff)
downloadopenttd-0243ae46547631c72e826ef28caae0637e7723dd.tar.xz
Fix #8799: NGameAllowedSorter() is not imposing strict weak ordering relation (#8801)
In other words, it should only (!) return true if A comes for B. This promise was broken for the situation where two values are identical. It would return true in these cases too. This is of course not possible: if two values are identical, neither come before the other. As such, the sorter was not imposing strict weak ordering relations. libstdc++ handled this scenario just fine, but libc++ crashes badly on this, as it allowed comparing of [begin, end] instead of [begin, end). libc++ considered this not a bug (and by specs, they are correct; just this way of crashing is of course a bit harsh): https://bugs.llvm.org/show_bug.cgi?id=47903
Diffstat (limited to 'src/company_manager_face.h')
0 files changed, 0 insertions, 0 deletions