changeset 36137:b8bbe589fd47

narrowspec: consistently use set() to copy sets Differential Revision: https://phab.mercurial-scm.org/D2191
author Augie Fackler <augie@google.com>
date Mon, 12 Feb 2018 14:37:10 -0500
parents 9c55bbc29dcf
children 8fd0a9e2d7e9
files hgext/narrow/narrowspec.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/narrow/narrowspec.py	Mon Feb 12 14:27:32 2018 -0500
+++ b/hgext/narrow/narrowspec.py	Mon Feb 12 14:37:10 2018 -0500
@@ -180,7 +180,7 @@
     >>> restrictpatterns({'f1/$non_exitent_var'}, {}, ['f1','f2'], [])
     (set(['f1/$non_exitent_var']), {})
     """
-    res_excludes = req_excludes.copy()
+    res_excludes = set(req_excludes)
     res_excludes.update(repo_excludes)
     if not req_includes:
         res_includes = set(repo_includes)