public function Twig_Node_Expression_Binary::compile

Compiles the node to PHP.

Parameters

Twig_Compiler A Twig_Compiler instance:

Overrides Twig_Node::compile

1 call to Twig_Node_Expression_Binary::compile()
Twig_Node_Expression_Binary_FloorDiv::compile in drupal/core/vendor/twig/twig/lib/Twig/Node/Expression/Binary/FloorDiv.php
Compiles the node to PHP.
5 methods override Twig_Node_Expression_Binary::compile()
Twig_Node_Expression_Binary_FloorDiv::compile in drupal/core/vendor/twig/twig/lib/Twig/Node/Expression/Binary/FloorDiv.php
Compiles the node to PHP.
Twig_Node_Expression_Binary_In::compile in drupal/core/vendor/twig/twig/lib/Twig/Node/Expression/Binary/In.php
Compiles the node to PHP.
Twig_Node_Expression_Binary_NotIn::compile in drupal/core/vendor/twig/twig/lib/Twig/Node/Expression/Binary/NotIn.php
Compiles the node to PHP.
Twig_Node_Expression_Binary_Power::compile in drupal/core/vendor/twig/twig/lib/Twig/Node/Expression/Binary/Power.php
Compiles the node to PHP.
Twig_Node_Expression_Binary_Range::compile in drupal/core/vendor/twig/twig/lib/Twig/Node/Expression/Binary/Range.php
Compiles the node to PHP.

File

drupal/core/vendor/twig/twig/lib/Twig/Node/Expression/Binary.php, line 24

Class

Twig_Node_Expression_Binary

Code

public function compile(Twig_Compiler $compiler) {
  $compiler
    ->raw('(')
    ->subcompile($this
    ->getNode('left'))
    ->raw(' ');
  $this
    ->operator($compiler);
  $compiler
    ->raw(' ')
    ->subcompile($this
    ->getNode('right'))
    ->raw(')');
}