Skip to content

Commit e974313

Browse files
committed
Merge branch '2.10.x' into 2.11.x
* 2.10.x: Add errors caused by the lexer update to the baselines (#9360)
2 parents e369cb6 + 1e972b6 commit e974313

File tree

2 files changed

+43
-20
lines changed

2 files changed

+43
-20
lines changed

phpstan-baseline.neon

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -965,6 +965,16 @@ parameters:
965965
count: 1
966966
path: lib/Doctrine/ORM/Query/Parser.php
967967

968+
-
969+
message: "#^Method Doctrine\\\\ORM\\\\Query\\\\Parser\\:\\:ArithmeticTerm\\(\\) should return Doctrine\\\\ORM\\\\Query\\\\AST\\\\ArithmeticTerm but returns Doctrine\\\\ORM\\\\Query\\\\AST\\\\ArithmeticFactor\\|string\\.$#"
970+
count: 1
971+
path: lib/Doctrine/ORM/Query/Parser.php
972+
973+
-
974+
message: "#^Method Doctrine\\\\ORM\\\\Query\\\\Parser\\:\\:SimpleArithmeticExpression\\(\\) should return Doctrine\\\\ORM\\\\Query\\\\AST\\\\SimpleArithmeticExpression but returns Doctrine\\\\ORM\\\\Query\\\\AST\\\\ArithmeticTerm\\|string\\.$#"
975+
count: 1
976+
path: lib/Doctrine/ORM/Query/Parser.php
977+
968978
-
969979
message: """
970980
#^PHPDoc tag @return has invalid value \\(AST\\\\BetweenExpression\\|
@@ -980,6 +990,11 @@ parameters:
980990
count: 1
981991
path: lib/Doctrine/ORM/Query/Parser.php
982992

993+
-
994+
message: "#^Parameter \\#1 \\$tokenType of method Doctrine\\\\ORM\\\\Query\\\\Parser\\:\\:isAggregateFunction\\(\\) expects 1\\|2\\|3\\|4\\|5\\|6\\|7\\|8\\|9\\|10\\|11\\|12\\|13\\|14\\|15\\|16\\|17\\|18\\|19\\|100\\|101\\|102\\|200\\|201\\|202\\|203\\|204\\|205\\|206\\|207\\|208\\|209\\|210\\|211\\|212\\|213\\|214\\|215\\|216\\|217\\|218\\|219\\|220\\|221\\|222\\|223\\|224\\|225\\|226\\|227\\|228\\|229\\|230\\|231\\|232\\|233\\|234\\|235\\|236\\|237\\|238\\|239\\|240\\|241\\|242\\|243\\|244\\|245\\|246\\|247\\|248\\|249\\|250\\|251\\|252\\|253\\|254\\|255\\|256, int\\|string\\|null given\\.$#"
995+
count: 2
996+
path: lib/Doctrine/ORM/Query/Parser.php
997+
983998
-
984999
message: "#^Parameter \\#2 \\$stringPattern of class Doctrine\\\\ORM\\\\Query\\\\AST\\\\LikeExpression constructor expects Doctrine\\\\ORM\\\\Query\\\\AST\\\\InputParameter, Doctrine\\\\ORM\\\\Query\\\\AST\\\\Node given\\.$#"
9851000
count: 1

psalm-baseline.xml

Lines changed: 28 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -653,8 +653,7 @@
653653
</RedundantCastGivenDocblockType>
654654
</file>
655655
<file src="lib/Doctrine/ORM/Mapping/ClassMetadata.php">
656-
<PropertyNotSetInConstructor occurrences="6">
657-
<code>ClassMetadata</code>
656+
<PropertyNotSetInConstructor occurrences="5">
658657
<code>ClassMetadata</code>
659658
<code>ClassMetadata</code>
660659
<code>ClassMetadata</code>
@@ -809,9 +808,8 @@
809808
<code>$mapping['originalField']</code>
810809
<code>$mapping['targetEntity']</code>
811810
</PossiblyUndefinedArrayOffset>
812-
<PropertyNotSetInConstructor occurrences="6">
811+
<PropertyNotSetInConstructor occurrences="5">
813812
<code>$idGenerator</code>
814-
<code>$isVersioned</code>
815813
<code>$namespace</code>
816814
<code>$sequenceGeneratorDefinition</code>
817815
<code>$table</code>
@@ -1604,10 +1602,6 @@
16041602
<MoreSpecificReturnType occurrences="1">
16051603
<code>executeInserts</code>
16061604
</MoreSpecificReturnType>
1607-
<RedundantConditionGivenDocblockType occurrences="2">
1608-
<code>$isVersioned</code>
1609-
<code>$isVersioned</code>
1610-
</RedundantConditionGivenDocblockType>
16111605
</file>
16121606
<file src="lib/Doctrine/ORM/Persisters/Entity/SingleTablePersister.php">
16131607
<PossiblyUndefinedVariable occurrences="1">
@@ -1870,6 +1864,9 @@
18701864
<PossiblyNullArrayOffset occurrences="1">
18711865
<code>$class-&gt;associationMappings</code>
18721866
</PossiblyNullArrayOffset>
1867+
<PossiblyNullPropertyAssignmentValue occurrences="1">
1868+
<code>$parser-&gt;getLexer()-&gt;token['value']</code>
1869+
</PossiblyNullPropertyAssignmentValue>
18731870
<PropertyNotSetInConstructor occurrences="2">
18741871
<code>$fieldMapping</code>
18751872
<code>$pathExpression</code>
@@ -1951,6 +1948,9 @@
19511948
<code>$lexer-&gt;lookahead['value']</code>
19521949
<code>$lexer-&gt;token['value']</code>
19531950
</PossiblyNullArrayAccess>
1951+
<PossiblyNullPropertyAssignmentValue occurrences="1">
1952+
<code>$lexer-&gt;token['value']</code>
1953+
</PossiblyNullPropertyAssignmentValue>
19541954
<PropertyNotSetInConstructor occurrences="4">
19551955
<code>$both</code>
19561956
<code>$leading</code>
@@ -2328,11 +2328,21 @@
23282328
<code>call_user_func($functionClass, $functionName)</code>
23292329
<code>call_user_func($functionClass, $functionName)</code>
23302330
</DocblockTypeContradiction>
2331-
<InvalidNullableReturnType occurrences="1">
2331+
<InvalidArgument occurrences="1">
2332+
<code>$lookaheadType</code>
2333+
</InvalidArgument>
2334+
<InvalidNullableReturnType occurrences="6">
23322335
<code>SelectStatement|UpdateStatement|DeleteStatement</code>
2336+
<code>string</code>
2337+
<code>string</code>
2338+
<code>string</code>
2339+
<code>string</code>
2340+
<code>string</code>
23332341
</InvalidNullableReturnType>
2334-
<InvalidReturnStatement occurrences="9">
2342+
<InvalidReturnStatement occurrences="11">
2343+
<code>$factors[0]</code>
23352344
<code>$primary</code>
2345+
<code>$terms[0]</code>
23362346
<code>$this-&gt;CollectionMemberExpression()</code>
23372347
<code>$this-&gt;ComparisonExpression()</code>
23382348
<code>$this-&gt;EmptyCollectionComparisonExpression()</code>
@@ -2342,9 +2352,11 @@
23422352
<code>$this-&gt;LikeExpression()</code>
23432353
<code>$this-&gt;NullComparisonExpression()</code>
23442354
</InvalidReturnStatement>
2345-
<InvalidReturnType occurrences="2">
2355+
<InvalidReturnType occurrences="4">
23462356
<code>AST\BetweenExpression|</code>
23472357
<code>ArithmeticFactor</code>
2358+
<code>ArithmeticTerm</code>
2359+
<code>SimpleArithmeticExpression</code>
23482360
</InvalidReturnType>
23492361
<InvalidScalarArgument occurrences="3">
23502362
<code>$this-&gt;lexer-&gt;getLiteral($token)</code>
@@ -2382,15 +2394,14 @@
23822394
<code>$this-&gt;ConditionalExpression()</code>
23832395
<code>$this-&gt;ConditionalExpression()</code>
23842396
</PossiblyInvalidPropertyAssignmentValue>
2385-
<PossiblyNullArgument occurrences="23">
2397+
<PossiblyNullArgument occurrences="22">
23862398
<code>$aliasIdentVariable</code>
23872399
<code>$dql</code>
23882400
<code>$field</code>
23892401
<code>$fromClassName</code>
23902402
<code>$functionName</code>
23912403
<code>$functionName</code>
23922404
<code>$functionName</code>
2393-
<code>$lookaheadType</code>
23942405
<code>$resultVariable</code>
23952406
<code>$this-&gt;lexer-&gt;lookahead['value']</code>
23962407
<code>$this-&gt;lexer-&gt;lookahead['value']</code>
@@ -2407,7 +2418,7 @@
24072418
<code>$token['value']</code>
24082419
<code>$token['value']</code>
24092420
</PossiblyNullArgument>
2410-
<PossiblyNullArrayAccess occurrences="75">
2421+
<PossiblyNullArrayAccess occurrences="74">
24112422
<code>$glimpse['type']</code>
24122423
<code>$glimpse['value']</code>
24132424
<code>$lookahead['type']</code>
@@ -2478,12 +2489,14 @@
24782489
<code>$token['type']</code>
24792490
<code>$token['type']</code>
24802491
<code>$token['type']</code>
2481-
<code>$token['type']</code>
24822492
<code>$token['value']</code>
24832493
<code>$token['value']</code>
24842494
<code>$token['value']</code>
24852495
<code>$token['value']</code>
24862496
</PossiblyNullArrayAccess>
2497+
<PossiblyNullPropertyAssignmentValue occurrences="1">
2498+
<code>$value</code>
2499+
</PossiblyNullPropertyAssignmentValue>
24872500
<PossiblyNullReference occurrences="1">
24882501
<code>getNumberOfRequiredParameters</code>
24892502
</PossiblyNullReference>
@@ -3119,11 +3132,6 @@
31193132
<code>configure</code>
31203133
</MissingReturnType>
31213134
</file>
3122-
<file src="lib/Doctrine/ORM/Tools/Console/ConsoleRunner.php">
3123-
<DeprecatedClass occurrences="1">
3124-
<code>Versions::getVersion('doctrine/orm')</code>
3125-
</DeprecatedClass>
3126-
</file>
31273135
<file src="lib/Doctrine/ORM/Tools/DebugUnitOfWorkListener.php">
31283136
<PossiblyNullArgument occurrences="2">
31293137
<code>$entity</code>

0 commit comments

Comments
 (0)