Open
Description
This valid code (from http://php.net/manual/en/functions.anonymous.php):
function ($quantity, $product) use ($tax, &$total)
{
$pricePerItem = constant(__CLASS__ . "::PRICE_" .
strtoupper($product));
$total += ($pricePerItem * $quantity) * ($tax + 1.0);
};
Gives this error:
Parse error: syntax error, unexpected T_STRING, expecting identifier in /console.htm on line 2
Metadata
Metadata
Assignees
Labels
No labels