Patchwork [3,of,4] revset: define _aliassyminitletters in terms of _syminitletters

login
register
mail settings
Submitter Augie Fackler
Date Oct. 7, 2016, 12:50 p.m.
Message ID <24645da251e864651097.1475844647@augie-macbookair2.roam.corp.google.com>
Download mbox | patch
Permalink /patch/16887/
State Superseded
Headers show

Comments

Augie Fackler - Oct. 7, 2016, 12:50 p.m.
# HG changeset patch
# User Augie Fackler <augie@google.com>
# Date 1475843560 14400
#      Fri Oct 07 08:32:40 2016 -0400
# Node ID 24645da251e8646510978321adfa03bc47952709
# Parent  d7777ef3fe7f82524c2925d9af6c3e1884a4188d
revset: define _aliassyminitletters in terms of _syminitletters

Patch

diff --git a/mercurial/revset.py b/mercurial/revset.py
--- a/mercurial/revset.py
+++ b/mercurial/revset.py
@@ -2619,8 +2619,7 @@  def optimize(tree):
 
 # the set of valid characters for the initial letter of symbols in
 # alias declarations and definitions
-_aliassyminitletters = set(c for c in [chr(i) for i in xrange(256)]
-                           if c.isalnum() or c in '._@$' or ord(c) > 127)
+_aliassyminitletters = _syminitletters | set(u'$')
 
 def _parsewith(spec, lookup=None, syminitletters=None):
     """Generate a parse tree of given spec with given tokenizing options