From 849f4b810f34e19f53ce8a8b16e6293dffdd9899 Mon Sep 17 00:00:00 2001 From: Gabriele Roeger Date: Sat, 20 Jan 2024 15:31:35 +0100 Subject: [PATCH] [issue1133] style check --- src/translate/constraints.py | 3 ++- src/translate/invariant_finder.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/translate/constraints.py b/src/translate/constraints.py index ed13be64a2..c5a80b59dc 100644 --- a/src/translate/constraints.py +++ b/src/translate/constraints.py @@ -163,7 +163,8 @@ def inequality_disjunction_ok(ineq_disj, representative): # inequality disjunction there is an inequality where the two terms # are in different equivalence classes. representative = combined.get_representative() - if any(representative.get(s,s)[0] != "?" for s in self.not_constant): + if any(representative.get(s, s)[0] != "?" + for s in self.not_constant): continue for ineq_disjunction in self.ineq_disjunctions: if not inequality_disjunction_ok(ineq_disjunction, diff --git a/src/translate/invariant_finder.py b/src/translate/invariant_finder.py index 14993849a1..d771233ac0 100755 --- a/src/translate/invariant_finder.py +++ b/src/translate/invariant_finder.py @@ -129,7 +129,7 @@ def useful_groups(invariants, initial_facts): inv_vars = [f"?@v{i}" for i in range(invariant.arity())] parameters_tuple = tuple((var, parameters[var]) for var in inv_vars) - + parameters_tuple = tuple(sorted(x for x in parameters.items())) group_key = (invariant, parameters_tuple) if group_key not in nonempty_groups: