diff --git a/phpstan.src.neon.dist b/phpstan.src.neon.dist index a1863637..389d3a75 100644 --- a/phpstan.src.neon.dist +++ b/phpstan.src.neon.dist @@ -3,3 +3,7 @@ parameters: ignoreErrors: - '#Only booleans are allowed in a negated boolean, int\|false given.#' - '#Method Dotenv\\Util\\Regex::split\(\) should return GrahamCampbell\\ResultType\\Result\, string\> but returns GrahamCampbell\\ResultType\\Result\, string\>.#' + - '#Anonymous function should return GrahamCampbell\\ResultType\\Result\ but returns GrahamCampbell\\ResultType\\Result\.#' + - '#Anonymous function should return GrahamCampbell\\ResultType\\Result\ but returns GrahamCampbell\\ResultType\\Result\, string\>.#' + - '#Parameter \#1 \$readers of class Dotenv\\Repository\\RepositoryBuilder constructor expects array\, array\ given\.#' + - '#Parameter \#2 \$writers of class Dotenv\\Repository\\RepositoryBuilder constructor expects array\, array\ given\.#' diff --git a/src/Parser/Lexer.php b/src/Parser/Lexer.php index c5eb64d3..981af24f 100644 --- a/src/Parser/Lexer.php +++ b/src/Parser/Lexer.php @@ -8,8 +8,6 @@ final class Lexer { /** * The regex for each type of token. - * - * @var string */ private const PATTERNS = [ '[\r\n]{1,1000}', '[^\S\r\n]{1,1000}', '\\\\', '\'', '"', '\\#', '\\$', '([^(\s\\\\\'"\\#\\$)]|\\(|\\)){1,1000}', @@ -45,8 +43,6 @@ public static function lex(string $content) $regex = '(('.\implode(')|(', self::PATTERNS).'))A'; } - $tokens = []; - $offset = 0; while (isset($content[$offset])) { diff --git a/src/Repository/RepositoryBuilder.php b/src/Repository/RepositoryBuilder.php index f8a92644..92f65e99 100644 --- a/src/Repository/RepositoryBuilder.php +++ b/src/Repository/RepositoryBuilder.php @@ -21,8 +21,6 @@ final class RepositoryBuilder { /** * The set of default adapters. - * - * @var string[] */ private const DEFAULT_ADAPTERS = [ ServerConstAdapter::class, diff --git a/src/Store/StoreBuilder.php b/src/Store/StoreBuilder.php index d1fb26fb..304117fc 100644 --- a/src/Store/StoreBuilder.php +++ b/src/Store/StoreBuilder.php @@ -10,8 +10,6 @@ final class StoreBuilder { /** * The of default name. - * - * @var string[] */ private const DEFAULT_NAME = '.env';