Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update baselines for Lexer 1.2.3 #9546

Merged
merged 1 commit into from
Feb 28, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"squizlabs/php_codesniffer": "3.6.2",
"symfony/cache": "^4.4 || ^5.4 || ^6.0",
"symfony/yaml": "^3.4 || ^4.0 || ^5.0 || ^6.0",
"vimeo/psalm": "4.20.0"
"vimeo/psalm": "4.22.0"
},
"conflict": {
"doctrine/annotations": "<1.13 || >= 2.0"
Expand Down
4 changes: 2 additions & 2 deletions phpstan-baseline.neon
Original file line number Diff line number Diff line change
Expand Up @@ -886,12 +886,12 @@ parameters:
path: lib/Doctrine/ORM/Query/Parser.php

-
message: "#^Method Doctrine\\\\ORM\\\\Query\\\\Parser\\:\\:ArithmeticTerm\\(\\) should return Doctrine\\\\ORM\\\\Query\\\\AST\\\\ArithmeticTerm but returns Doctrine\\\\ORM\\\\Query\\\\AST\\\\ArithmeticFactor\\|string\\.$#"
message: "#^Method Doctrine\\\\ORM\\\\Query\\\\Parser\\:\\:ArithmeticTerm\\(\\) should return Doctrine\\\\ORM\\\\Query\\\\AST\\\\ArithmeticTerm but returns Doctrine\\\\ORM\\\\Query\\\\AST\\\\ArithmeticFactor\\|int\\|string\\.$#"
count: 1
path: lib/Doctrine/ORM/Query/Parser.php

-
message: "#^Method Doctrine\\\\ORM\\\\Query\\\\Parser\\:\\:SimpleArithmeticExpression\\(\\) should return Doctrine\\\\ORM\\\\Query\\\\AST\\\\SimpleArithmeticExpression but returns Doctrine\\\\ORM\\\\Query\\\\AST\\\\ArithmeticTerm\\|string\\.$#"
message: "#^Method Doctrine\\\\ORM\\\\Query\\\\Parser\\:\\:SimpleArithmeticExpression\\(\\) should return Doctrine\\\\ORM\\\\Query\\\\AST\\\\SimpleArithmeticExpression but returns Doctrine\\\\ORM\\\\Query\\\\AST\\\\ArithmeticTerm\\|int\\|string\\.$#"
count: 1
path: lib/Doctrine/ORM/Query/Parser.php

Expand Down
93 changes: 52 additions & 41 deletions psalm-baseline.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<files psalm-version="4.20.0@f82a70e7edfc6cf2705e9374c8a0b6a974a779ed">
<files psalm-version="4.22.0@fc2c6ab4d5fa5d644d8617089f012f3bb84b8703">
<file src="lib/Doctrine/ORM/AbstractQuery.php">
<DeprecatedClass occurrences="1">
<code>IterableResult</code>
Expand Down Expand Up @@ -1833,15 +1833,15 @@
</ParamNameMismatch>
</file>
<file src="lib/Doctrine/ORM/Query/AST/Functions/IdentityFunction.php">
<PossiblyInvalidPropertyAssignmentValue occurrences="1">
<code>$parser-&gt;getLexer()-&gt;token['value']</code>
</PossiblyInvalidPropertyAssignmentValue>
<PossiblyNullArrayAccess occurrences="1">
<code>$parser-&gt;getLexer()-&gt;token['value']</code>
</PossiblyNullArrayAccess>
<PossiblyNullArrayOffset occurrences="1">
<code>$class-&gt;associationMappings</code>
</PossiblyNullArrayOffset>
<PossiblyNullPropertyAssignmentValue occurrences="1">
<code>$parser-&gt;getLexer()-&gt;token['value']</code>
</PossiblyNullPropertyAssignmentValue>
<PropertyNotSetInConstructor occurrences="2">
<code>$fieldMapping</code>
<code>$pathExpression</code>
Expand Down Expand Up @@ -1916,16 +1916,18 @@
</PropertyNotSetInConstructor>
</file>
<file src="lib/Doctrine/ORM/Query/AST/Functions/TrimFunction.php">
<PossiblyNullArgument occurrences="1">
<PossiblyInvalidArgument occurrences="3">
<code>$value</code>
</PossiblyNullArgument>
<code>$value</code>
<code>$value</code>
</PossiblyInvalidArgument>
<PossiblyInvalidPropertyAssignmentValue occurrences="1">
<code>$lexer-&gt;token['value']</code>
</PossiblyInvalidPropertyAssignmentValue>
<PossiblyNullArrayAccess occurrences="2">
<code>$lexer-&gt;lookahead['value']</code>
<code>$lexer-&gt;token['value']</code>
</PossiblyNullArrayAccess>
<PossiblyNullPropertyAssignmentValue occurrences="1">
<code>$lexer-&gt;token['value']</code>
</PossiblyNullPropertyAssignmentValue>
<PropertyNotSetInConstructor occurrences="4">
<code>$both</code>
<code>$leading</code>
Expand Down Expand Up @@ -2305,17 +2307,16 @@
<InvalidArgument occurrences="1">
<code>$lookaheadType</code>
</InvalidArgument>
<InvalidNullableReturnType occurrences="6">
<InvalidNullableReturnType occurrences="1">
<code>SelectStatement|UpdateStatement|DeleteStatement</code>
<code>string</code>
<code>string</code>
<code>string</code>
<code>string</code>
<code>string</code>
</InvalidNullableReturnType>
<InvalidReturnStatement occurrences="11">
<InvalidReturnStatement occurrences="17">
<code>$aliasIdentVariable</code>
<code>$factors[0]</code>
<code>$identVariable</code>
<code>$primary</code>
<code>$resultVariable</code>
<code>$resultVariable</code>
<code>$terms[0]</code>
<code>$this-&gt;CollectionMemberExpression()</code>
<code>$this-&gt;ComparisonExpression()</code>
Expand All @@ -2325,23 +2326,44 @@
<code>$this-&gt;InstanceOfExpression()</code>
<code>$this-&gt;LikeExpression()</code>
<code>$this-&gt;NullComparisonExpression()</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
</InvalidReturnStatement>
<InvalidReturnType occurrences="4">
<InvalidReturnType occurrences="9">
<code>AST\BetweenExpression|</code>
<code>ArithmeticFactor</code>
<code>ArithmeticTerm</code>
<code>SimpleArithmeticExpression</code>
<code>string</code>
<code>string</code>
<code>string</code>
<code>string</code>
<code>string</code>
</InvalidReturnType>
<InvalidScalarArgument occurrences="3">
<InvalidScalarArgument occurrences="13">
<code>$field</code>
<code>$field</code>
<code>$functionName</code>
<code>$functionName</code>
<code>$functionName</code>
<code>$this-&gt;lexer-&gt;getLiteral($token)</code>
<code>$this-&gt;lexer-&gt;getLiteral($token)</code>
<code>$this-&gt;lexer-&gt;getLiteral($token)</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
</InvalidScalarArgument>
<LessSpecificReturnStatement occurrences="3">
<LessSpecificReturnStatement occurrences="4">
<code>$function</code>
<code>$function</code>
<code>$function</code>
<code>$token</code>
</LessSpecificReturnStatement>
<MoreSpecificReturnType occurrences="1">
<code>array{value: string, type: int|null|string, position: int}|null</code>
</MoreSpecificReturnType>
<NullableReturnStatement occurrences="9">
<code>$aliasIdentVariable</code>
<code>$factors[0]</code>
Expand All @@ -2356,41 +2378,33 @@
<PossiblyFalseArgument occurrences="1">
<code>strrpos($fromClassName, '\\')</code>
</PossiblyFalseArgument>
<PossiblyInvalidArgument occurrences="6">
<PossiblyInvalidArgument occurrences="13">
<code>$AST</code>
<code>$conditionalExpression</code>
<code>$expr</code>
<code>$stringExpr</code>
<code>$this-&gt;ConditionalExpression()</code>
<code>$this-&gt;ConditionalExpression()</code>
<code>$this-&gt;lexer-&gt;lookahead['value']</code>
<code>$this-&gt;lexer-&gt;lookahead['value']</code>
<code>$this-&gt;lexer-&gt;lookahead['value']</code>
<code>$this-&gt;lexer-&gt;lookahead['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$token['value']</code>
<code>$token['value']</code>
</PossiblyInvalidArgument>
<PossiblyInvalidPropertyAssignmentValue occurrences="2">
<PossiblyInvalidPropertyAssignmentValue occurrences="3">
<code>$this-&gt;ConditionalExpression()</code>
<code>$this-&gt;ConditionalExpression()</code>
<code>$value</code>
</PossiblyInvalidPropertyAssignmentValue>
<PossiblyNullArgument occurrences="22">
<PossiblyNullArgument occurrences="6">
<code>$aliasIdentVariable</code>
<code>$dql</code>
<code>$field</code>
<code>$fromClassName</code>
<code>$functionName</code>
<code>$functionName</code>
<code>$functionName</code>
<code>$resultVariable</code>
<code>$this-&gt;lexer-&gt;lookahead['value']</code>
<code>$this-&gt;lexer-&gt;lookahead['value']</code>
<code>$this-&gt;lexer-&gt;lookahead['value']</code>
<code>$this-&gt;lexer-&gt;lookahead['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;lexer-&gt;token['value']</code>
<code>$this-&gt;query-&gt;getDQL()</code>
<code>$token['value']</code>
<code>$token['value']</code>
<code>$token['value']</code>
</PossiblyNullArgument>
<PossiblyNullArrayAccess occurrences="74">
<code>$glimpse['type']</code>
Expand Down Expand Up @@ -2468,9 +2482,6 @@
<code>$token['value']</code>
<code>$token['value']</code>
</PossiblyNullArrayAccess>
<PossiblyNullPropertyAssignmentValue occurrences="1">
<code>$value</code>
</PossiblyNullPropertyAssignmentValue>
<PossiblyNullReference occurrences="1">
<code>getNumberOfRequiredParameters</code>
</PossiblyNullReference>
Expand Down