summaryrefslogtreecommitdiff
path: root/scss/types.py
diff options
context:
space:
mode:
authorEevee (Alex Munroe) <eevee.git@veekun.com>2013-10-08 12:00:24 -0700
committerEevee (Alex Munroe) <eevee.git@veekun.com>2013-10-08 12:00:24 -0700
commit20cb364f146e6e53a2308aa09adc6ddfa235ea43 (patch)
tree50da74f92b04a7aec2a3a70416d65d8138adf053 /scss/types.py
parent5d7f56be690bcaf3b7b7dce6507aa06c067f31ec (diff)
downloadpyscss-20cb364f146e6e53a2308aa09adc6ddfa235ea43.tar.gz
Lists built from function calls are not "literal".
Diffstat (limited to 'scss/types.py')
-rw-r--r--scss/types.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/scss/types.py b/scss/types.py
index 4a027d7..aafbab4 100644
--- a/scss/types.py
+++ b/scss/types.py
@@ -685,7 +685,13 @@ class List(Value):
max_list, min_list = (self, other) if len(self) > len(other) else (other, self)
return List([item + max_list[i] for i, item in enumerate(min_list)], use_comma=self.use_comma)
- return List([item + other for item in self], use_comma=self.use_comma)
+ elif isinstance(other, String):
+ # UN-DEVIATION: adding a string should fall back to canonical
+ # behavior of string addition
+ return super(List, self).__add__(other)
+
+ else:
+ return List([item + other for item in self], use_comma=self.use_comma)
def __sub__(self, other):
if isinstance(other, List):