Permalink
Browse files

Fixed or binop regression. Closes #475

  • Loading branch information...
1 parent f7d5b48 commit 98599ff006113e1a4b7c170506fa419d246c8b9b @tj tj committed Nov 30, 2011
Showing with 16 additions and 1 deletion.
  1. +3 −1 lib/nodes/expression.js
  2. +6 −0 test/cases/regression.475.css
  3. +7 −0 test/cases/regression.475.styl
@@ -144,7 +144,9 @@ Expression.prototype.operate = function(op, right, val){
// check the return value, and return the lhs expr
// as a whole rather than the first item
var ret = this.first.operate(op, right, val);
- return ret == this.nodes[0] ? this : right;
+ return ret.isTrue
+ ? this.nodes[0]
+ : right;
case 'in':
return Node.prototype.operate.call(this, op, right);
case '!=':
@@ -0,0 +1,6 @@
+body {
+ foo: true;
+ foo: true;
+ foo: true;
+ foo: true;
+}
@@ -0,0 +1,7 @@
+only = webkit
+
+body
+ foo: webkit in only
+ foo: (webkit in only)
+ foo: true or false
+ foo: (webkit in only) or false

0 comments on commit 98599ff

Please sign in to comment.