Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
typemytype committed May 30, 2024
2 parents 06c8772 + 788e7d9 commit 01c89d0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Lib/ufoProcessor/ufoOperator.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def immutify(obj):
# make an immutable version of this object.
# assert immutify(10) == (10,)
# assert immutify([10, 20, "a"]) == (10, 20, 'a')
# assert immutify(dict(foo="bar", world=["a", "b"])) == ('foo', ('bar',), 'world', ('a', 'b'))
# assert immutify(dict(aSet={1,2,3}, foo="bar", world=["a", "b"])) == ('foo', ('bar',), 'world', ('a', 'b'))
hashValues = []
if isinstance(obj, dict):
hashValues.append(
Expand All @@ -48,7 +48,7 @@ def immutify(obj):
)
elif isinstance(obj, set):
for value in sorted(obj):
hashValues.extend(immutify(value))
hashValues.append(immutify(value))
elif isinstance(obj, (list, tuple)):
for value in obj:
hashValues.append(immutify(value))
Expand Down

0 comments on commit 01c89d0

Please sign in to comment.