summaryrefslogtreecommitdiff
path: root/inc/lib/Twig/Node/Expression/Binary
diff options
context:
space:
mode:
authorAppleman1234 <applemansigloo@gmail.com>2022-09-25 13:22:40 +1000
committerAppleman1234 <applemansigloo@gmail.com>2022-09-25 13:22:40 +1000
commit92561d7f36508b7e0271926e417adf0e2e53916b (patch)
treea8588b4f70af276c5acf58836e33b1f6ff5c61e8 /inc/lib/Twig/Node/Expression/Binary
parent6f1083e4b51fc9c4c594f6c72cf3d84ef4d0298b (diff)
Initial attempt a switch to composer and PHP-8.1 compatibility
Diffstat (limited to 'inc/lib/Twig/Node/Expression/Binary')
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Add.php20
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/And.php20
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/BitwiseAnd.php20
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/BitwiseOr.php20
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/BitwiseXor.php20
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Concat.php20
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Div.php20
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/EndsWith.php32
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Equal.php19
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/FloorDiv.php26
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Greater.php19
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/GreaterEqual.php19
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/In.php30
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Less.php19
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/LessEqual.php19
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Matches.php30
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Mod.php20
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Mul.php20
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/NotEqual.php19
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/NotIn.php30
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Or.php20
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Power.php34
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Range.php30
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/StartsWith.php32
-rw-r--r--inc/lib/Twig/Node/Expression/Binary/Sub.php20
25 files changed, 0 insertions, 578 deletions
diff --git a/inc/lib/Twig/Node/Expression/Binary/Add.php b/inc/lib/Twig/Node/Expression/Binary/Add.php
deleted file mode 100644
index 5a09d836..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Add.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Add extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('+');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Add', 'Twig\Node\Expression\Binary\AddBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/And.php b/inc/lib/Twig/Node/Expression/Binary/And.php
deleted file mode 100644
index 9ffddce6..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/And.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_And extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('&&');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_And', 'Twig\Node\Expression\Binary\AndBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/BitwiseAnd.php b/inc/lib/Twig/Node/Expression/Binary/BitwiseAnd.php
deleted file mode 100644
index e46e9ebf..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/BitwiseAnd.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_BitwiseAnd extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('&');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_BitwiseAnd', 'Twig\Node\Expression\Binary\BitwiseAndBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/BitwiseOr.php b/inc/lib/Twig/Node/Expression/Binary/BitwiseOr.php
deleted file mode 100644
index 5d7f1b7c..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/BitwiseOr.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_BitwiseOr extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('|');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_BitwiseOr', 'Twig\Node\Expression\Binary\BitwiseOrBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/BitwiseXor.php b/inc/lib/Twig/Node/Expression/Binary/BitwiseXor.php
deleted file mode 100644
index 82edf516..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/BitwiseXor.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_BitwiseXor extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('^');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_BitwiseXor', 'Twig\Node\Expression\Binary\BitwiseXorBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Concat.php b/inc/lib/Twig/Node/Expression/Binary/Concat.php
deleted file mode 100644
index 91abca60..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Concat.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Concat extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('.');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Concat', 'Twig\Node\Expression\Binary\ConcatBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Div.php b/inc/lib/Twig/Node/Expression/Binary/Div.php
deleted file mode 100644
index 38ffa30c..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Div.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Div extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('/');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Div', 'Twig\Node\Expression\Binary\DivBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/EndsWith.php b/inc/lib/Twig/Node/Expression/Binary/EndsWith.php
deleted file mode 100644
index 85c52937..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/EndsWith.php
+++ /dev/null
@@ -1,32 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_EndsWith extends Twig_Node_Expression_Binary
-{
- public function compile(Twig_Compiler $compiler)
- {
- $left = $compiler->getVarName();
- $right = $compiler->getVarName();
- $compiler
- ->raw(sprintf('(is_string($%s = ', $left))
- ->subcompile($this->getNode('left'))
- ->raw(sprintf(') && is_string($%s = ', $right))
- ->subcompile($this->getNode('right'))
- ->raw(sprintf(') && (\'\' === $%2$s || $%2$s === substr($%1$s, -strlen($%2$s))))', $left, $right))
- ;
- }
-
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_EndsWith', 'Twig\Node\Expression\Binary\EndsWithBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Equal.php b/inc/lib/Twig/Node/Expression/Binary/Equal.php
deleted file mode 100644
index a6a6946b..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Equal.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Equal extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('==');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Equal', 'Twig\Node\Expression\Binary\EqualBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/FloorDiv.php b/inc/lib/Twig/Node/Expression/Binary/FloorDiv.php
deleted file mode 100644
index 7393bcb8..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/FloorDiv.php
+++ /dev/null
@@ -1,26 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_FloorDiv extends Twig_Node_Expression_Binary
-{
- public function compile(Twig_Compiler $compiler)
- {
- $compiler->raw('(int) floor(');
- parent::compile($compiler);
- $compiler->raw(')');
- }
-
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('/');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_FloorDiv', 'Twig\Node\Expression\Binary\FloorDivBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Greater.php b/inc/lib/Twig/Node/Expression/Binary/Greater.php
deleted file mode 100644
index 832f9797..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Greater.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Greater extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('>');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Greater', 'Twig\Node\Expression\Binary\GreaterBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/GreaterEqual.php b/inc/lib/Twig/Node/Expression/Binary/GreaterEqual.php
deleted file mode 100644
index c5f76245..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/GreaterEqual.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_GreaterEqual extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('>=');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_GreaterEqual', 'Twig\Node\Expression\Binary\GreaterEqualBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/In.php b/inc/lib/Twig/Node/Expression/Binary/In.php
deleted file mode 100644
index af112448..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/In.php
+++ /dev/null
@@ -1,30 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_In extends Twig_Node_Expression_Binary
-{
- public function compile(Twig_Compiler $compiler)
- {
- $compiler
- ->raw('twig_in_filter(')
- ->subcompile($this->getNode('left'))
- ->raw(', ')
- ->subcompile($this->getNode('right'))
- ->raw(')')
- ;
- }
-
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('in');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_In', 'Twig\Node\Expression\Binary\InBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Less.php b/inc/lib/Twig/Node/Expression/Binary/Less.php
deleted file mode 100644
index ab8fc1f9..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Less.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Less extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('<');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Less', 'Twig\Node\Expression\Binary\LessBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/LessEqual.php b/inc/lib/Twig/Node/Expression/Binary/LessEqual.php
deleted file mode 100644
index 71a279e9..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/LessEqual.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_LessEqual extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('<=');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_LessEqual', 'Twig\Node\Expression\Binary\LessEqualBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Matches.php b/inc/lib/Twig/Node/Expression/Binary/Matches.php
deleted file mode 100644
index 5cb85584..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Matches.php
+++ /dev/null
@@ -1,30 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Matches extends Twig_Node_Expression_Binary
-{
- public function compile(Twig_Compiler $compiler)
- {
- $compiler
- ->raw('preg_match(')
- ->subcompile($this->getNode('right'))
- ->raw(', ')
- ->subcompile($this->getNode('left'))
- ->raw(')')
- ;
- }
-
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Matches', 'Twig\Node\Expression\Binary\MatchesBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Mod.php b/inc/lib/Twig/Node/Expression/Binary/Mod.php
deleted file mode 100644
index 28109633..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Mod.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Mod extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('%');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Mod', 'Twig\Node\Expression\Binary\ModBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Mul.php b/inc/lib/Twig/Node/Expression/Binary/Mul.php
deleted file mode 100644
index 790c6a22..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Mul.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Mul extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('*');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Mul', 'Twig\Node\Expression\Binary\MulBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/NotEqual.php b/inc/lib/Twig/Node/Expression/Binary/NotEqual.php
deleted file mode 100644
index bb45c9ed..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/NotEqual.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_NotEqual extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('!=');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_NotEqual', 'Twig\Node\Expression\Binary\NotEqualBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/NotIn.php b/inc/lib/Twig/Node/Expression/Binary/NotIn.php
deleted file mode 100644
index 9dedf92f..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/NotIn.php
+++ /dev/null
@@ -1,30 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_NotIn extends Twig_Node_Expression_Binary
-{
- public function compile(Twig_Compiler $compiler)
- {
- $compiler
- ->raw('!twig_in_filter(')
- ->subcompile($this->getNode('left'))
- ->raw(', ')
- ->subcompile($this->getNode('right'))
- ->raw(')')
- ;
- }
-
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('not in');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_NotIn', 'Twig\Node\Expression\Binary\NotInBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Or.php b/inc/lib/Twig/Node/Expression/Binary/Or.php
deleted file mode 100644
index dc9eece1..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Or.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Or extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('||');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Or', 'Twig\Node\Expression\Binary\OrBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Power.php b/inc/lib/Twig/Node/Expression/Binary/Power.php
deleted file mode 100644
index d24777bd..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Power.php
+++ /dev/null
@@ -1,34 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Power extends Twig_Node_Expression_Binary
-{
- public function compile(Twig_Compiler $compiler)
- {
- if (PHP_VERSION_ID >= 50600) {
- return parent::compile($compiler);
- }
-
- $compiler
- ->raw('pow(')
- ->subcompile($this->getNode('left'))
- ->raw(', ')
- ->subcompile($this->getNode('right'))
- ->raw(')')
- ;
- }
-
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('**');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Power', 'Twig\Node\Expression\Binary\PowerBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Range.php b/inc/lib/Twig/Node/Expression/Binary/Range.php
deleted file mode 100644
index 187f6765..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Range.php
+++ /dev/null
@@ -1,30 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Range extends Twig_Node_Expression_Binary
-{
- public function compile(Twig_Compiler $compiler)
- {
- $compiler
- ->raw('range(')
- ->subcompile($this->getNode('left'))
- ->raw(', ')
- ->subcompile($this->getNode('right'))
- ->raw(')')
- ;
- }
-
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('..');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Range', 'Twig\Node\Expression\Binary\RangeBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/StartsWith.php b/inc/lib/Twig/Node/Expression/Binary/StartsWith.php
deleted file mode 100644
index 7e43b8de..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/StartsWith.php
+++ /dev/null
@@ -1,32 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_StartsWith extends Twig_Node_Expression_Binary
-{
- public function compile(Twig_Compiler $compiler)
- {
- $left = $compiler->getVarName();
- $right = $compiler->getVarName();
- $compiler
- ->raw(sprintf('(is_string($%s = ', $left))
- ->subcompile($this->getNode('left'))
- ->raw(sprintf(') && is_string($%s = ', $right))
- ->subcompile($this->getNode('right'))
- ->raw(sprintf(') && (\'\' === $%2$s || 0 === strpos($%1$s, $%2$s)))', $left, $right))
- ;
- }
-
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_StartsWith', 'Twig\Node\Expression\Binary\StartsWithBinary', false);
diff --git a/inc/lib/Twig/Node/Expression/Binary/Sub.php b/inc/lib/Twig/Node/Expression/Binary/Sub.php
deleted file mode 100644
index cff8ed07..00000000
--- a/inc/lib/Twig/Node/Expression/Binary/Sub.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-
-/*
- * This file is part of Twig.
- *
- * (c) Fabien Potencier
- * (c) Armin Ronacher
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-class Twig_Node_Expression_Binary_Sub extends Twig_Node_Expression_Binary
-{
- public function operator(Twig_Compiler $compiler)
- {
- return $compiler->raw('-');
- }
-}
-
-class_alias('Twig_Node_Expression_Binary_Sub', 'Twig\Node\Expression\Binary\SubBinary', false);