File tree Expand file tree Collapse file tree 3 files changed +6
-18
lines changed
source/Plugins/LanguageRuntime/ObjC Expand file tree Collapse file tree 3 files changed +6
-18
lines changed Original file line number Diff line number Diff line change @@ -48,9 +48,8 @@ class CompilerDeclContext {
4848 explicit operator bool () const { return IsValid (); }
4949
5050 bool operator <(const CompilerDeclContext &rhs) const {
51- if (m_type_system == rhs.m_type_system )
52- return m_opaque_decl_ctx < rhs.m_opaque_decl_ctx ;
53- return m_type_system < rhs.m_type_system ;
51+ return std::tie (m_type_system, m_opaque_decl_ctx) <
52+ std::tie (rhs.m_type_system , rhs.m_opaque_decl_ctx );
5453 }
5554
5655 bool IsValid () const {
Original file line number Diff line number Diff line change @@ -30,11 +30,8 @@ struct CoreFileMemoryRange {
3030 }
3131
3232 bool operator <(const CoreFileMemoryRange &rhs) const {
33- if (range < rhs.range )
34- return true ;
35- if (range == rhs.range )
36- return lldb_permissions < rhs.lldb_permissions ;
37- return false ;
33+ return std::tie (range, lldb_permissions) <
34+ std::tie (rhs.range , rhs.lldb_permissions );
3835 }
3936
4037 std::string Dump () const {
Original file line number Diff line number Diff line change @@ -386,16 +386,8 @@ class ObjCLanguageRuntime : public LanguageRuntime {
386386 }
387387
388388 bool operator <(const ClassAndSel &rhs) const {
389- if (class_addr < rhs.class_addr )
390- return true ;
391- else if (class_addr > rhs.class_addr )
392- return false ;
393- else {
394- if (sel_addr < rhs.sel_addr )
395- return true ;
396- else
397- return false ;
398- }
389+ return std::tie (class_addr, sel_addr) <
390+ std::tie (rhs.class_addr , rhs.sel_addr );
399391 }
400392
401393 lldb::addr_t class_addr = LLDB_INVALID_ADDRESS;
You can’t perform that action at this time.
0 commit comments