⬆️ N°3867 Upgrade php-parser from 3.1.5 to latest version 4.12.0

The 3.1.5 version wasn't maintained anymore and was compatible with PHP 7.2 maximum
This commit is contained in:
Pierre Goiffon
2021-08-09 14:58:06 +02:00
parent be1ef5b452
commit 9bbee0d603
248 changed files with 12185 additions and 11258 deletions

View File

@@ -1,4 +1,4 @@
<?php
<?php declare(strict_types=1);
namespace PhpParser\ErrorHandler;
@@ -24,7 +24,7 @@ class Collecting implements ErrorHandler
*
* @return Error[]
*/
public function getErrors() {
public function getErrors() : array {
return $this->errors;
}
@@ -33,7 +33,7 @@ class Collecting implements ErrorHandler
*
* @return bool
*/
public function hasErrors() {
public function hasErrors() : bool {
return !empty($this->errors);
}
@@ -43,4 +43,4 @@ class Collecting implements ErrorHandler
public function clearErrors() {
$this->errors = [];
}
}
}

View File

@@ -1,4 +1,4 @@
<?php
<?php declare(strict_types=1);
namespace PhpParser\ErrorHandler;
@@ -15,4 +15,4 @@ class Throwing implements ErrorHandler
public function handleError(Error $error) {
throw $error;
}
}
}