diff options
author | Kevin Pulo <kevin.pulo@mongodb.com> | 2020-10-26 17:11:18 +1100 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-11-02 09:58:44 +0000 |
commit | 7d8e64df2d2d56a821f638ef88aa619403d03d31 (patch) | |
tree | 6ada2d481c56b9754ec7848caf146cd94149148f /src/mongo/db/query/index_bounds_builder.cpp | |
parent | 4d2dea00415bf02d2b32d0474c93d251ce6568cc (diff) | |
download | mongo-7d8e64df2d2d56a821f638ef88aa619403d03d31.tar.gz |
SERVER-44570 Add tripwire assertions (tassert)
Diffstat (limited to 'src/mongo/db/query/index_bounds_builder.cpp')
-rw-r--r-- | src/mongo/db/query/index_bounds_builder.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mongo/db/query/index_bounds_builder.cpp b/src/mongo/db/query/index_bounds_builder.cpp index 54f2846cdc0..e423f60844c 100644 --- a/src/mongo/db/query/index_bounds_builder.cpp +++ b/src/mongo/db/query/index_bounds_builder.cpp @@ -574,7 +574,9 @@ void IndexBoundsBuilder::_translatePredicate(const MatchExpression* expr, // values. One exception is for collation, whose index bounds are tracked as INEXACT_FETCH, // but only because the index data is different than the user data, not because the range // is imprecise. - invariant(*tightnessOut == IndexBoundsBuilder::EXACT || index.collator); + tassert(4457011, + "Cannot invert inexact bounds", + *tightnessOut == IndexBoundsBuilder::EXACT || index.collator); // If the index is multikey on this path, it doesn't matter what the tightness of the child // is, we must return INEXACT_FETCH. Consider a multikey index on 'a' with document |