# HG changeset patch # User Bryan O'Sullivan # Date 1448411934 28800 # Node ID 9de814b35808827d55980a438be18a2846612b13 # Parent f04bd381e8c09a5d42bac305fc9fee51a924ce71 extensions: rename _ignore to _builtin, add descriptive comment It was previously not at all obvious what this was for. We also change it to a set to avoid iterating over an admittedly small list repeatedly at startup time. diff -r f04bd381e8c0 -r 9de814b35808 mercurial/extensions.py --- a/mercurial/extensions.py Sun Nov 22 14:44:55 2015 -0800 +++ b/mercurial/extensions.py Tue Nov 24 16:38:54 2015 -0800 @@ -24,7 +24,8 @@ _extensions = {} _aftercallbacks = {} _order = [] -_ignore = ['hbisect', 'bookmarks', 'parentrevspec', 'interhg', 'inotify'] +# former extensions now in core - we ignore these if found in hgrc +_builtin = set(['hbisect', 'bookmarks', 'parentrevspec', 'interhg', 'inotify']) def extensions(ui=None): if ui: @@ -75,7 +76,7 @@ shortname = name[6:] else: shortname = name - if shortname in _ignore: + if shortname in _builtin: return None if shortname in _extensions: return _extensions[shortname]