mirror of
https://github.com/MaskRay/ccls.git
synced 2024-11-26 01:21:57 +00:00
Fix MSVC compile
This commit is contained in:
parent
e38c6103ea
commit
39b9991c8f
@ -17,8 +17,9 @@ struct Ipc_CqueryMemberHierarchyExpand
|
||||
const static IpcId kIpcId = IpcId::CqueryMemberHierarchyExpand;
|
||||
lsRequestId id;
|
||||
struct Params {
|
||||
size_t type_id;
|
||||
} params;
|
||||
uint64_t type_id;
|
||||
};
|
||||
Params params;
|
||||
};
|
||||
MAKE_REFLECT_STRUCT(Ipc_CqueryMemberHierarchyExpand::Params, type_id);
|
||||
MAKE_REFLECT_STRUCT(Ipc_CqueryMemberHierarchyExpand, id, params);
|
||||
@ -28,7 +29,7 @@ struct Out_CqueryMemberHierarchy
|
||||
: public lsOutMessage<Out_CqueryMemberHierarchy> {
|
||||
struct Entry {
|
||||
std::string name;
|
||||
uint64_t type_id;
|
||||
uint64_t type_id; // FIXME: should be size_t
|
||||
lsLocation location;
|
||||
};
|
||||
lsRequestId id;
|
||||
@ -73,7 +74,7 @@ ExpandNode(QueryDatabase* db,
|
||||
Out_CqueryMemberHierarchy::Entry entry;
|
||||
entry.name = var.def->short_name;
|
||||
entry.type_id =
|
||||
var.def->variable_type ? var.def->variable_type->id : size_t(-1);
|
||||
var.def->variable_type ? var.def->variable_type->id : uint64_t(-1);
|
||||
if (var.def->definition_spelling) {
|
||||
optional<lsLocation> loc =
|
||||
GetLsLocation(db, working_files, *var.def->definition_spelling);
|
||||
@ -124,7 +125,7 @@ struct CqueryMemberHierarchyExpandHandler
|
||||
Out_CqueryMemberHierarchy out;
|
||||
out.id = request->id;
|
||||
// |ExpandNode| uses -1 to indicate invalid |type_id|.
|
||||
if (request->params.type_id != size_t(-1))
|
||||
if (request->params.type_id != uint64_t(-1))
|
||||
out.result =
|
||||
ExpandNode(db, working_files, QueryTypeId(request->params.type_id));
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user