Skip to content

Commit

Permalink
Add missing argument 'self' to checkConflict method.
Browse files Browse the repository at this point in the history
--HG--
branch : dev
  • Loading branch information
felix.antoine.fortin committed Aug 16, 2012
1 parent 5f959fb commit 75542eb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/ga/sortingnetwork.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def addConnector(self, wire1, wire2):

index = 0
for level in reversed(self):
if checkConflict(level, wire1, wire2):
if self.checkConflict(level, wire1, wire2):
break
index -= 1

Expand All @@ -59,7 +59,7 @@ def addConnector(self, wire1, wire2):
else:
self[index].append((wire1, wire2))

def checkConflict(level, wire1, wire2):
def checkConflict(self, level, wire1, wire2):
"""Check if a connection between `wire1` and `wire2` can be
added on this `level`."""
for wires in level:
Expand Down

0 comments on commit 75542eb

Please sign in to comment.