diff options
author | Eevee (Alex Munroe) <eevee.git@veekun.com> | 2014-12-10 15:32:48 -0800 |
---|---|---|
committer | Eevee (Alex Munroe) <eevee.git@veekun.com> | 2014-12-10 15:32:48 -0800 |
commit | 5c8345d387607408409537eb4869ffa0640ba64c (patch) | |
tree | 2a8b5a575ce5f8eea0517ea22b6bcd0bc88cb583 | |
parent | f957acd97788a7fb12f1f6b1947c41bc9ead6aaa (diff) | |
download | pyscss-5c8345d387607408409537eb4869ffa0640ba64c.tar.gz |
Avoid u'' for 3.2's sake.
-rw-r--r-- | scss/rule.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/scss/rule.py b/scss/rule.py index b8bf8c9..32dd74a 100644 --- a/scss/rule.py +++ b/scss/rule.py @@ -1,5 +1,6 @@ from __future__ import absolute_import from __future__ import print_function +from __future__ import unicode_literals import logging import re @@ -77,6 +78,8 @@ class SassRule(object): self.descendants = 0 def __repr__(self): + # TODO probably want to encode this with string_escape on python 2, and + # similar elsewhere, especially since this file has unicode_literals return "<SassRule %s, %d props>" % ( self.ancestry, len(self.properties), @@ -245,7 +248,7 @@ class BlockHeader(object): # e.g. identifiers aren't supposed to begin with three hyphens. # But we don't care, and will just spit it back out anyway. m = re.match( - u'@(else if|[-_a-zA-Z0-9\U00000080-\U0010FFFF]*)\\b', + '@(else if|[-_a-zA-Z0-9\U00000080-\U0010FFFF]*)\\b', prop, re.I) directive = m.group(0).lower() argument = prop[len(directive):].strip() |