formatting: force pointers/references with the type

This commit is contained in:
Jake Hillion 2023-03-22 09:16:17 -07:00 committed by Jake Hillion
parent 2e74fa357a
commit d2caaf22e8
40 changed files with 1047 additions and 1049 deletions

View File

@ -6,3 +6,5 @@ AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: false
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
DerivePointerAlignment: false
PointerAlignment: Left

View File

@ -46,8 +46,7 @@ struct DrgnClassMemberInfo {
};
struct TypeHierarchy {
std::map<struct drgn_type *, std::vector<DrgnClassMemberInfo>>
classMembersMap;
std::map<struct drgn_type*, std::vector<DrgnClassMemberInfo>> classMembersMap;
std::map<struct drgn_type*,
std::pair<ContainerInfo, std::vector<struct drgn_qualified_type>>>
containerTypeMap;
@ -56,6 +55,5 @@ struct TypeHierarchy {
std::set<struct drgn_type*> knownDummyTypeList;
std::map<struct drgn_type*, struct drgn_type*> pointerToTypeMap;
std::set<struct drgn_type*> thriftIssetStructTypes;
std::map<struct drgn_type *, std::vector<struct drgn_type *>>
descendantClasses;
std::map<struct drgn_type*, std::vector<struct drgn_type*>> descendantClasses;
};

View File

@ -2090,8 +2090,8 @@ void OICodeGen::getClassMembersIncludingParent(
}
}
std::map<drgn_type *, std::vector<DrgnClassMemberInfo>>
&OICodeGen::getClassMembersMap() {
std::map<drgn_type*, std::vector<DrgnClassMemberInfo>>&
OICodeGen::getClassMembersMap() {
for (auto& e : classMembersMap) {
std::vector<DrgnClassMemberInfo> v;
getClassMembersIncludingParent(e.first, v);

View File

@ -546,8 +546,8 @@ bool OIDebugger::locateObjectsAddresses(const trapInfo &tInfo,
}
VLOG(4) << "Entry: arg addr: " << std::hex << *addr;
if (!writeTargetMemory((void *)(&addr.value()),
(void *)remoteObjAddr->second, sizeof(*addr))) {
if (!writeTargetMemory((void*)(&addr.value()), (void*)remoteObjAddr->second,
sizeof(*addr))) {
LOG(ERROR) << "Entry: writeTargetMemory remoteObjAddr failed!";
ret = false;
continue;

View File

@ -195,10 +195,8 @@ class OIDebugger {
bool writeTargetMemory(void*, void*, size_t) const;
bool readTargetMemory(void*, void*, size_t) const;
std::optional<std::pair<OIDebugger::ObjectAddrMap::key_type, uintptr_t>>
locateJitCodeStart(const irequest &,
const OICompiler::RelocResult::SymTable &);
bool writePrologue(const prequest &,
const OICompiler::RelocResult::SymTable &);
locateJitCodeStart(const irequest&, const OICompiler::RelocResult::SymTable&);
bool writePrologue(const prequest&, const OICompiler::RelocResult::SymTable&);
bool readInstFromTarget(uintptr_t, uint8_t*, size_t);
void createSegmentConfigFile(void);
void deleteSegmentConfig(bool);