From 70bba41561848d241623ba14e60d5c87cca137ab Mon Sep 17 00:00:00 2001 From: David Grudl Date: Tue, 7 Aug 2018 18:15:45 +0200 Subject: [PATCH] PhpParser: token_get_all() uses flag TOKEN_PARSE --- src/CodeCoverage/PhpParser.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/CodeCoverage/PhpParser.php b/src/CodeCoverage/PhpParser.php index 2e755116..f4185fdf 100644 --- a/src/CodeCoverage/PhpParser.php +++ b/src/CodeCoverage/PhpParser.php @@ -53,7 +53,7 @@ class PhpParser */ public function parse(string $code): \stdClass { - $tokens = @token_get_all($code); // @ - source code can be written in newer PHP + $tokens = token_get_all($code, TOKEN_PARSE); $level = $classLevel = $functionLevel = null; $namespace = '';