Skip to content

Commit

Permalink
Fix minor things
Browse files Browse the repository at this point in the history
  • Loading branch information
fabpot committed Sep 6, 2024
1 parent a7e497a commit 978f749
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Node/MacroNode.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public function compile(Compiler $compiler): void
;
}

$node = new CaptureNode($this->getNode('body'), $this->getNode('body')->lineno, $this->getNode('body')->tag);
$node = new CaptureNode($this->getNode('body'), $this->getNode('body')->lineno);

$compiler
->write('')
Expand Down
2 changes: 1 addition & 1 deletion src/Util/ReflectionCallable.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ final class ReflectionCallable
private $name;

public function __construct(
private TwigCallableInterface $twigCallable,
TwigCallableInterface $twigCallable,
) {
$callable = $twigCallable->getCallable();
if (\is_string($callable) && false !== $pos = strpos($callable, '::')) {
Expand Down
2 changes: 1 addition & 1 deletion tests/TokenParser/TypesTokenParserTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class TypesTokenParserTest extends TestCase
public function testMappingParsing(string $template, array $expected): void
{
$env = new Environment(new ArrayLoader(), ['cache' => false, 'autoescape' => false]);
$stream = $env->tokenize($source = new Source($template, ''));
$stream = $env->tokenize(new Source($template, ''));
$parser = new Parser($env);

$typesNode = $parser->parse($stream)->getNode('body')->getNode('0');
Expand Down

0 comments on commit 978f749

Please sign in to comment.