Skip to content

Commit be2364e

Browse files
committed
add != color op + tests, fixes leafo#79
1 parent b618128 commit be2364e

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

scss.inc.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1029,6 +1029,8 @@ protected function op_color_color($op, $left, $right) {
10291029
break;
10301030
case "==":
10311031
return $this->op_eq($left, $right);
1032+
case "!=":
1033+
return $this->op_neq($left, $right);
10321034
default:
10331035
$this->throwError("color: unknown op $op");
10341036
}

tests/inputs/operators.scss

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,12 @@ div {
4747
color: rgba(1,2,3, 0.5) - 2;
4848

4949
color: blue + 34;
50+
51+
color: #fff == #000;
52+
color: #fff == #fff;
53+
54+
color: #fff != #000;
55+
color: #fff != #fff;
5056
}
5157

5258

0 commit comments

Comments
 (0)