* {{ var is even }} * * * @package twig * @author Fabien Potencier */ class Twig_Node_Expression_Test_Even extends Twig_Node_Expression_Test { public function compile(Twig_Compiler $compiler) { $compiler ->raw('(') ->subcompile($this->getNode('node')) ->raw(' % 2 == 0') ->raw(')') ; } }