schmittjoh/twig.js — pull request #70 by kokec (2013-08-26 09:42:52+00:00)
Title: added brackets for sameas test to pass test negation

Twig code for sameas test
```twig
{% if name is not sameas(false) %}
Hello not false!
{% endif %}
```
compiles with twig.js into
```javascript
if ((!("name" in context ? context["name"] : null) === false)) {
sb.append("Hello not false!\n");
}
```

so, the first expression negation
```javascript
!("name" in context ? context["name"] : null)
````
is compared to false. But in twig i have the negation of sameas(false). And i get !0 === false, that gives false, and should get !(0 === false) and true as a result.
So i want to get
```javascript
if ((!(("name" in context ? context["name"] : null) === false))) {
sb.append("Hello not false!\n");
}
```
to negate the entire expression.