diff mercurial/encoding.py @ 32291:bd872f64a8ba

cleanup: use set literals We no longer support Python 2.6, so we can now use set literals.
author Martin von Zweigbergk <martinvonz@google.com>
date Fri, 10 Feb 2017 16:56:29 -0800
parents 1a3a08b5d4d5
children 7040f5131454
line wrap: on
line diff
--- a/mercurial/encoding.py	Sat May 06 04:51:25 2017 +0530
+++ b/mercurial/encoding.py	Fri Feb 10 16:56:29 2017 -0800
@@ -30,9 +30,9 @@
            "206a 206b 206c 206d 206e 206f feff".split()]
 # verify the next function will work
 if pycompat.ispy3:
-    assert set(i[0] for i in _ignore) == set([ord(b'\xe2'), ord(b'\xef')])
+    assert set(i[0] for i in _ignore) == {ord(b'\xe2'), ord(b'\xef')}
 else:
-    assert set(i[0] for i in _ignore) == set(["\xe2", "\xef"])
+    assert set(i[0] for i in _ignore) == {"\xe2", "\xef"}
 
 def hfsignoreclean(s):
     """Remove codepoints ignored by HFS+ from s.