Please use GitHub pull requests for new patches. Avoid migrating existing patches. Phabricator shutdown timeline
Changeset View
Changeset View
Standalone View
Standalone View
lldb/source/API/SBValue.cpp
Show First 20 Lines • Show All 1,425 Lines • ▼ Show 20 Lines | error.SetErrorStringWithFormat( | ||||
"Couldn't set data: could not get SBValue: %s", | "Couldn't set data: could not get SBValue: %s", | ||||
locker.GetError().AsCString()); | locker.GetError().AsCString()); | ||||
ret = false; | ret = false; | ||||
} | } | ||||
return ret; | return ret; | ||||
} | } | ||||
lldb::SBValue SBValue::Clone(const char *new_name) { | |||||
LLDB_RECORD_METHOD(lldb::SBValue, SBValue, Clone, (const char *), new_name); | |||||
ValueLocker locker; | |||||
lldb::ValueObjectSP value_sp(GetSP(locker)); | |||||
if (value_sp) | |||||
return lldb::SBValue(value_sp->Clone(ConstString(new_name))); | |||||
else | |||||
labath: https://llvm.org/docs/CodingStandards.html#don-t-use-else-after-a-return | |||||
return lldb::SBValue(); | |||||
} | |||||
lldb::SBDeclaration SBValue::GetDeclaration() { | lldb::SBDeclaration SBValue::GetDeclaration() { | ||||
LLDB_RECORD_METHOD_NO_ARGS(lldb::SBDeclaration, SBValue, GetDeclaration); | LLDB_RECORD_METHOD_NO_ARGS(lldb::SBDeclaration, SBValue, GetDeclaration); | ||||
ValueLocker locker; | ValueLocker locker; | ||||
lldb::ValueObjectSP value_sp(GetSP(locker)); | lldb::ValueObjectSP value_sp(GetSP(locker)); | ||||
SBDeclaration decl_sb; | SBDeclaration decl_sb; | ||||
if (value_sp) { | if (value_sp) { | ||||
Declaration decl; | Declaration decl; | ||||
▲ Show 20 Lines • Show All 209 Lines • ▼ Show 20 Lines | void RegisterMethods<SBValue>(Registry &R) { | ||||
LLDB_REGISTER_METHOD(lldb::SBValue, SBValue, AddressOf, ()); | LLDB_REGISTER_METHOD(lldb::SBValue, SBValue, AddressOf, ()); | ||||
LLDB_REGISTER_METHOD(lldb::addr_t, SBValue, GetLoadAddress, ()); | LLDB_REGISTER_METHOD(lldb::addr_t, SBValue, GetLoadAddress, ()); | ||||
LLDB_REGISTER_METHOD(lldb::SBAddress, SBValue, GetAddress, ()); | LLDB_REGISTER_METHOD(lldb::SBAddress, SBValue, GetAddress, ()); | ||||
LLDB_REGISTER_METHOD(lldb::SBData, SBValue, GetPointeeData, | LLDB_REGISTER_METHOD(lldb::SBData, SBValue, GetPointeeData, | ||||
(uint32_t, uint32_t)); | (uint32_t, uint32_t)); | ||||
LLDB_REGISTER_METHOD(lldb::SBData, SBValue, GetData, ()); | LLDB_REGISTER_METHOD(lldb::SBData, SBValue, GetData, ()); | ||||
LLDB_REGISTER_METHOD(bool, SBValue, SetData, | LLDB_REGISTER_METHOD(bool, SBValue, SetData, | ||||
(lldb::SBData &, lldb::SBError &)); | (lldb::SBData &, lldb::SBError &)); | ||||
LLDB_REGISTER_METHOD(lldb::SBValue, SBValue, Clone, (const char *)); | |||||
LLDB_REGISTER_METHOD(lldb::SBDeclaration, SBValue, GetDeclaration, ()); | LLDB_REGISTER_METHOD(lldb::SBDeclaration, SBValue, GetDeclaration, ()); | ||||
LLDB_REGISTER_METHOD(lldb::SBWatchpoint, SBValue, Watch, | LLDB_REGISTER_METHOD(lldb::SBWatchpoint, SBValue, Watch, | ||||
(bool, bool, bool, lldb::SBError &)); | (bool, bool, bool, lldb::SBError &)); | ||||
LLDB_REGISTER_METHOD(lldb::SBWatchpoint, SBValue, Watch, | LLDB_REGISTER_METHOD(lldb::SBWatchpoint, SBValue, Watch, | ||||
(bool, bool, bool)); | (bool, bool, bool)); | ||||
LLDB_REGISTER_METHOD(lldb::SBWatchpoint, SBValue, WatchPointee, | LLDB_REGISTER_METHOD(lldb::SBWatchpoint, SBValue, WatchPointee, | ||||
(bool, bool, bool, lldb::SBError &)); | (bool, bool, bool, lldb::SBError &)); | ||||
LLDB_REGISTER_METHOD(lldb::SBValue, SBValue, Persist, ()); | LLDB_REGISTER_METHOD(lldb::SBValue, SBValue, Persist, ()); | ||||
} | } | ||||
} | } | ||||
} | } |
https://llvm.org/docs/CodingStandards.html#don-t-use-else-after-a-return