mirror of
https://github.com/phabelio/PHP-Parser.git
synced 2025-01-22 21:31:14 +01:00
8f623fb241
The dispatch using $this->{'reduceRule' . $rule}() is very expensive because it involves * One allocation when converting $rule to a string * Another allocation when concatenating the two strings * Lowercasing during the method call * Various uncached method checks, e.g. visibility. Using an array of closures for semantic action dispatch is significantly more efficient.