coco 31ad9f0: nodes: made Op::invert more accurate

This commit is contained in:
Jeremy Ashkenas
2010-11-14 15:07:43 -05:00
parent a1aaa4495c
commit f31798bbb4
3 changed files with 25 additions and 13 deletions

View File

@@ -54,11 +54,17 @@ ok result
# Should be able to handle switches sans-condition.
result = switch
when null then 1
when 'truthful string' then 2
else 3
when null then 0
when !1 then 1
when '' not of {''} then 2
when [] not instanceof Array then 3
when true is false then 4
when 'x' < 'y' > 'z' then 5
when 'a' in ['b', 'c'] then 6
when 'd' in (['e', 'f']) then 7
else ok
ok result is 2
eq result, ok
# Should be able to use "@properties" within the switch clause.