Bruce Weirdan
2530b33dbd
Merge pull request #7076 from klimick/fix-generic-assertion
2021-12-07 08:08:48 +02:00
orklah
257d237192
ignore ComplexMethod: didn't see any easy refactoring
2021-12-06 20:13:33 +01:00
orklah
75312d93b1
Don't crash when checking purity of __callStatic in a trait
2021-12-06 19:00:37 +01:00
Ricardo Boss
2ec77fe29c
Make name property of enum cases return non-empty-strings ( vimeo/psalm#6964 )
2021-12-06 00:33:57 +01:00
adrew
dee3fc4358
try to fix generic assertions for list and array
2021-12-06 02:25:40 +03:00
rarila
39402c233d
Return type hints ( #7065 )
...
Co-authored-by: ralila <>
2021-12-05 19:51:26 +02:00
orklah
f67a0ca143
Merge pull request #7068 from klimick/fix-yield
...
Detect yield in array expression
2021-12-05 16:25:21 +01:00
Ricardo Boss
8a230110e8
Fix vimeo/psalm#6968
2021-12-05 15:43:38 +01:00
adrew
bc61547bce
detect yield in array expression
2021-12-05 15:33:18 +03:00
Bruce Weirdan
e9d9481ea6
Merge pull request #7060 from rarila/codingstyle-convert-fqn
2021-12-05 02:46:03 +02:00
ralila
9902898c4d
Remove unnecessary bug circumvention and generate new baseline
2021-12-05 01:15:29 +01:00
Matthew Brown
1956b85c41
Remove always-false args ( #7056 )
2021-12-04 10:40:52 -05:00
ralila
f833085a15
Fix fqn usage in php-doc
2021-12-04 03:37:19 +01:00
ralila
30a65685a2
Import instead of using fqn classes
2021-12-03 21:40:18 +01:00
ralila
7c32325e03
Import instead of using fqn constants
2021-12-03 21:25:22 +01:00
ralila
2a956498bf
Import instead of using fqn functions
2021-12-03 21:07:25 +01:00
ralila
711be643c6
Import instead of using fqn exceptions
2021-12-03 20:29:06 +01:00
ralila
245920e53c
Import instead of using fqn
2021-12-03 20:11:20 +01:00
orklah
a7e9eea0ca
flag usage of get_class outside class without args ( #7043 )
2021-12-02 00:38:45 +02:00
Bruce Weirdan
28c4f86993
Merge pull request #7027 from rarila/issue-6914
2021-11-30 23:34:00 +02:00
orklah
466137a4c4
Merge pull request #7025 from orklah/6256
...
flag DeprecatedProperty on static fetch
2021-11-29 23:46:25 +01:00
orklah
328dcb093b
fix variable name
2021-11-29 23:41:47 +01:00
orklah
9de9c12851
flag DeprecatedProperty on static fetch
2021-11-29 23:32:27 +01:00
Matthew Brown
175ba83332
Migrate most IssueBuffer::accepts calls to IssueBuffer::maybeAdd ( #7020 )
2021-11-29 14:54:17 -05:00
ralila
15eb8127ee
Reverse parameter list vor preg_match
2021-11-29 14:23:33 +01:00
Bruce Weirdan
28a75652ac
Merge pull request #6997 from zoonru/list_values_paradox
2021-11-29 00:47:12 +02:00
925df22052
Use simplified, proper logic
2021-11-28 13:42:30 +01:00
Bruce Weirdan
806db287d2
Infer ::from()
and ::tryFrom()
return types on backed enums
...
Fixes vimeo/psalm#6429
2021-11-28 09:47:01 +02:00
Bruce Weirdan
03aea28c73
Merge pull request #6995 from vimeo/enum-constants
2021-11-27 21:49:13 +02:00
Bruce Weirdan
97445b52f3
Correctly process constant references on enum-valued variables
2021-11-27 04:32:32 +02:00
Bruce Weirdan
d19aad7db1
Display target PHP version
...
Historically it was often not quite clear to users what PHP version
Psalm assumes, and why. This PR addresses this issue by printing the
version and where we got it from right before scanning the files.
2021-11-27 02:18:09 +02:00
orklah
72de3b66cc
Merge pull request #7003 from rarila/no-phpdoc-return-void
...
Use return type hints instead of php doc "@return void"
2021-11-26 23:03:28 +01:00
2145a2cbbd
Make sure that the keyed array is actually a list after unsetting
2021-11-26 21:52:34 +01:00
00ab986c06
Update IfElseAnalyzer.php
2021-11-26 21:47:17 +01:00
ee8c5c9c35
Remove some array_values
2021-11-26 21:47:17 +01:00
1129ab1475
Raise RedundantCast when using array_values on a list
2021-11-26 21:47:14 +01:00
orklah
a27e729263
Merge pull request #7002 from orklah/listkeyedarray
...
Disable list flag for TKeyedArray after unset
2021-11-26 21:32:55 +01:00
ralila
fdaed941ad
use return type hints instead of php doc "@return void"
2021-11-26 20:59:41 +01:00
orklah
4f223db455
Disable list flag for TKeyedArray after unset
2021-11-26 20:52:34 +01:00
Bruce Weirdan
f215ed28d0
Drop special handling of constant references on enums
...
Internally enum cases are constants, and they should be resolved as
such.
Fixes vimeo/psalm#6994
2021-11-26 06:00:01 +02:00
orklah
2fbad1bbeb
Merge pull request #6993 from orklah/taint-numerics
...
Taint can't be transmitted through numerics nor bool
2021-11-25 23:20:38 +01:00
orklah
ab61eae5c9
Taint can't transmit through numerics nor bool
2021-11-25 22:51:35 +01:00
orklah
3bc06a8eab
Taint can't transmit through numerics nor bool
2021-11-25 22:40:01 +01:00
Paweł Tomulik
dac8c98613
attempt to fix #6973
2021-11-23 20:26:07 +01:00
orklah
b42c2814a9
Merge pull request #6971 from orklah/empty-keys
...
fix counting array properties when some are Never
2021-11-23 20:11:47 +01:00
Paweł Tomulik
a7b9a241f3
attempt to fix #6937
2021-11-22 23:24:20 +01:00
orklah
eca56c0c1a
Merge pull request #6972 from orklah/unused-throws
...
prevent Psalm from considering throwing methods as unused just because they're immutable
2021-11-22 22:00:55 +01:00
orklah
1c1e352e5f
prevent Psalm from considering throwing methods as unused just because they're immutable
2021-11-22 21:29:57 +01:00
orklah
0d47722195
fix counting array properties when some are Never
2021-11-22 21:13:25 +01:00
orklah
79fa7f5993
Merge pull request #6953 from orklah/callstatic-pure
...
check __callStatic purity instead of the pseudoMethod purity
2021-11-21 23:02:07 +01:00