php-parser/test/code/prettyPrinter/expr/closure.test
2020-06-27 17:57:47 +02:00

21 lines
404 B
Plaintext

Closures
-----
<?php
$closureWithArgs = function (
$arg1,
$arg2
) {
$comment = 'closure body';
};
$closureWithArgsAndVars = function ($arg1, $arg2) use($var1, $var2) {
$comment = 'closure body';
};
-----
$closureWithArgs = function ($arg1, $arg2) {
$comment = 'closure body';
};
$closureWithArgsAndVars = function ($arg1, $arg2) use($var1, $var2) {
$comment = 'closure body';
};