mirror of
https://github.com/phabelio/PHP-Parser.git
synced 2024-12-11 16:49:43 +01:00
21 lines
404 B
Plaintext
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';
|
|
}; |