Description
I am unable to compile mongo 3.4.10 from source. There is an error:
Compiling build/opt/mongo/db/query/planner_access.o
|
In file included from src/mongo/platform/compiler.h:151:0,
|
from src/mongo/util/invariant.h:30,
|
from src/mongo/base/string_data.h:41,
|
from build/opt/mongo/base/error_codes.h:32,
|
from src/mongo/base/status.h:34,
|
from src/mongo/db/query/canonical_query.h:32,
|
from src/mongo/db/query/planner_access.h:31,
|
from src/mongo/db/query/planner_access.cpp:33:
|
src/mongo/db/query/planner_access.cpp: In static member function 'static mongo::QuerySolutionNode* mongo::QueryPlannerAccess::buildIndexedDataAccess(const mongo::CanonicalQuery&, mongo::MatchExpression*, bool, const std::vector<mongo::IndexEntry>&, const mongo::QueryPlannerParams&)':
|
src/mongo/util/invariant.h:51:41: error: enum constant in boolean context [-Werror=int-in-bool-context]
|
if (MONGO_unlikely(!(_Expression))) { \
|
^
|
src/mongo/platform/compiler_gcc.h:77:80: note: in definition of macro 'MONGO_unlikely'
|
MONGO_unlikely(x) static_cast<bool>(__builtin_expect(static_cast<bool>(x), 0))
|
^
|
src/mongo/util/invariant.h:56:19: note: in expansion of macro 'MONGO_invariant'
|
#define invariant MONGO_invariant
|
^~~~~~~~~~~~~~~
|
src/mongo/db/query/planner_access.cpp:1218:13: note: in expansion of macro 'invariant'
|
invariant(MatchExpression::ELEM_MATCH_OBJECT);
|
^~~~~~~~~
|
cc1plus: all warnings being treated as errors
|
scons: *** [build/opt/mongo/db/query/planner_access.o] Error 1
|
scons: building terminated because of errors.
|
build/opt/mongo/db/query/planner_access.o failed: Error 1
|
Attachments
Issue Links
- duplicates
-
SERVER-28425 Fix mistyped QueryPlannerAccess invariant
-
- Closed
-