This is just a comment explaining the use of the local variables.
---
 eeschema/dialogs/dialog_erc.cpp | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/eeschema/dialogs/dialog_erc.cpp b/eeschema/dialogs/dialog_erc.cpp
index 2f9a1f2..7323a64 100644
--- a/eeschema/dialogs/dialog_erc.cpp
+++ b/eeschema/dialogs/dialog_erc.cpp
@@ -496,6 +496,15 @@ void DIALOG_ERC::TestErc( wxArrayString* aMessagesList )
     unsigned nextItem = lastItem = 0;
     int MinConn    = NOC;
 
+    /** The netlist generated by SCH_EDIT_FRAME::BuildNetListBase is sorted
+     * by net number, which means we can group netlist items into ranges
+     * that live in the same net. The range from nextItem to the current
+     * item (exclusive) needs to be checked against the current item. The
+     * lastItem variable is used as a helper to pass the last item's number
+     * from one loop iteration to the next, which simplifies the initial
+     * pass.
+     */
+
     for( unsigned item = 0; item < objectsConnectedList->size(); item++ )
     {
         if( objectsConnectedList->GetItemNet( lastItem ) !=
_______________________________________________
Mailing list: https://launchpad.net/~kicad-developers
Post to     : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp

Reply via email to