Skip to content

Commit 3deefdf

Browse files
committed
Fix comparision of double quoted strings
1 parent fad76c8 commit 3deefdf

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

eval.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1110,8 +1110,10 @@ namespace Sass {
11101110
} break;
11111111

11121112
case Expression::STRING: {
1113-
return unquote(static_cast<String_Constant*>(lhs)->value()) ==
1114-
unquote(static_cast<String_Constant*>(rhs)->value());
1113+
string slhs = static_cast<String_Quoted*>(lhs)->value();
1114+
string srhs = static_cast<String_Quoted*>(rhs)->value();
1115+
return unquote(slhs) == unquote(srhs) &&
1116+
(!(is_quoted(slhs) || is_quoted(srhs)) || slhs[0] == srhs[0]);
11151117
} break;
11161118

11171119
case Expression::LIST: {

0 commit comments

Comments
 (0)