From 5e1dc788c557e52154e7dd610edc4673094a7ba2 Mon Sep 17 00:00:00 2001 From: Clifford Wolf Date: Fri, 4 Dec 2015 12:10:11 +0100 Subject: Python3 fixes --- icebox/icebox.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'icebox/icebox.py') diff --git a/icebox/icebox.py b/icebox/icebox.py index a6f3111..398bfe8 100644 --- a/icebox/icebox.py +++ b/icebox/icebox.py @@ -940,10 +940,8 @@ def get_carry_bit(tile): def get_negclk_bit(tile): return tile[0][0] -def cmp_netnames(a, b): - a = re.sub(r"\d+", lambda m: "%09d" % int(m.group(0)), a) - b = re.sub(r"\d+", lambda m: "%09d" % int(m.group(0)), b) - return cmp(a, b) +def key_netname(netname): + return re.sub(r"\d+", lambda m: "%09d" % int(m.group(0)), netname) def run_checks_neigh(): print("Running consistency checks on neighbour finder..") -- cgit v1.2.3