From 1380feef72f6955130e918a4b1339972d38d5a9b Mon Sep 17 00:00:00 2001 From: Seth Hillbrand Date: Mon, 23 Oct 2023 12:52:52 -0700 Subject: [PATCH] Compare bus local names When running ERC, we want to check if bus members exist in the bus and this should be done using m_local_name (i.e. the name it take from the parent bus) not the resolved name as this will change depending on connections --- eeschema/connection_graph.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/eeschema/connection_graph.cpp b/eeschema/connection_graph.cpp index 40706e971a..18f750038a 100644 --- a/eeschema/connection_graph.cpp +++ b/eeschema/connection_graph.cpp @@ -3133,7 +3133,7 @@ bool CONNECTION_GRAPH::ercCheckBusToBusEntryConflicts( const CONNECTION_SUBGRAPH bus_name = bus_wire->Connection( &sheet )->Name(); std::set test_names; - test_names.insert( bus_entry->Connection( &sheet )->Name() ); + test_names.insert( bus_entry->Connection( &sheet )->FullLocalName() ); wxString baseName = sheet.PathHumanReadable(); @@ -3146,11 +3146,11 @@ bool CONNECTION_GRAPH::ercCheckBusToBusEntryConflicts( const CONNECTION_SUBGRAPH { for( const auto& sub_member : member->Members() ) { - if( test_names.count( sub_member->Name() ) ) + if( test_names.count( sub_member->FullLocalName() ) ) conflict = false; } } - else if( test_names.count( member->Name() ) ) + else if( test_names.count( member->FullLocalName() ) ) { conflict = false; }