Matt Brown
cfe2e81629
Fix #4791 - only generate special has-array-key assertions for unknown key types
2021-01-29 11:47:18 +01:00
Matt Brown
b15384bbff
Tighten up rules arouund when mutation-free methods get memoised
2021-01-29 11:47:18 +01:00
Matt Brown
35ed9d4d8d
Fix #4812 - reconcile array assertion on template as type correctly
2021-01-29 11:47:18 +01:00
Matt Brown
2ff3f867c5
Fix #4803 - always derive method params the same way
2021-01-29 11:47:18 +01:00
Matt Brown
91115d651f
Use better stubs for Serializable and SoapClient
2021-01-29 11:47:18 +01:00
2e3s
df8d2e2296
Overwrite memoized return type after sum-type candidate is calculated ( #4805 )
...
* Overwrite memoized return type after sum-type candidate is calculated
* Fix mismatched types
* Fix code style
2021-01-29 11:47:18 +01:00
Matt Brown
7825a71351
Fix #4797 - sanitise assertion output of template result
2021-01-29 11:47:18 +01:00
Matt Brown
50611d5b91
Fix #4798 - improve conversion from type back to PhpParser node
2021-01-29 11:47:18 +01:00
Matt Brown
5e4bece7d3
Fix #4802 - don’t clone context when analysing coalesce
2021-01-29 11:47:17 +01:00
Matthew Brown
9ccce95fba
Fix typo
2021-01-29 11:47:17 +01:00
Matt Brown
9f4c697109
Add more to SimpleXMLElement stub
2021-01-29 11:47:17 +01:00
Matt Brown
ae8aaaf1d8
Support simple list assignment in foreach
...
Ref #4741
2021-01-29 11:47:17 +01:00
Matt Brown
ce9d100908
Fix #4794 - invvalidate dependent types when their variables change
2021-01-29 11:47:17 +01:00
Jack Bentley
35fc84cdbb
Fix functions being resolved to other functions ( #4793 )
...
Fixes #4750
Reusing the $function_id variable causes an incorrect global function to be added at line 654
2021-01-29 11:47:17 +01:00
Bruce Weirdan
7cc512c9dc
Adjust check for file modification time ( #4789 )
...
This solves the issue where Psalm didn't notice the files created in the
same second as the last run was started.
2021-01-29 11:47:17 +01:00
Bruce Weirdan
54b705ec79
Added a workflow to test on PHP 8 / Linux ( #4790 )
...
Currently we already test on PHP 8 on AppVeyor, but the failures there
may be windows-specific, so it makes sense to test on Linux as well
2021-01-29 11:47:17 +01:00
orklah
37f0cd6263
Don't add link if the issue doesn't have a shortcode ( #4786 )
2021-01-29 11:47:16 +01:00
orklah
7a217a060d
allow passing mixed in is_a ( #4780 )
2021-01-29 11:47:16 +01:00
Matt Brown
c4b1c63dd1
Taint all when conditional return is used
...
Ref #4792
2021-01-29 11:47:16 +01:00
Matt Brown
a5408aafc9
Fix #4778 - remove already-initialized properties when checking initialisation
2021-01-29 11:47:16 +01:00
Matt Brown
551a5d84ab
Add PHP8-compat stub for SimpleXMLElement::current
2021-01-29 11:47:16 +01:00
Matt Brown
8bfb0412e7
Fix #4782 - don’t replace closure types with upper bounds when replacing class param types
2021-01-29 11:47:16 +01:00
Matt Brown
4f9449b742
Return earlier
2021-01-29 11:47:15 +01:00
Vincent Langlet
ad87d1bacc
Fix support of extraFiles ( #4785 )
2021-01-29 11:47:15 +01:00
Matt Brown
b21e138cc7
Allow nested specialisation
2021-01-29 11:47:15 +01:00
Matt Brown
309c13700d
Fix #4769 – don’t use unique ids for new generated nodes
2021-01-29 11:47:15 +01:00
orklah
ca26acd31e
improve pg_fetch return types ( #4777 )
2021-01-29 11:47:15 +01:00
Bruce Weirdan
5bce554cbb
Fix windows builds ( #4775 )
...
* Choco now offers PHP 8 only
* Bump build deps to allow PHP 8 builds
* Bump slevomat
* Disable coverage to allow paratest
* Bump dummy project version to allow testing on PHP 8
2021-01-29 11:47:15 +01:00
Matt Brown
910d617608
Fix redundancies
2021-01-29 11:47:14 +01:00
Matt Brown
326c47ef75
Fix implicit void closure not getting recognised
2021-01-29 11:47:14 +01:00
Matt Brown
9f52e84e54
Add back PSL
2021-01-29 11:47:14 +01:00
Matt Brown
73fc7d9491
Fix #4767 - rescan directly-affected class-interface relationships
2021-01-29 11:47:14 +01:00
orklah
48f55f3c3b
Allow int casts if the type comes from calculation ( #4768 )
2021-01-29 11:47:14 +01:00
Alies Lapatsin
c60eada3f7
#4772 Mark 3rd argument of get_headers nullable and optional ( #4774 )
...
There is no documentation that $context is nullable but it’s better to mark is nullable and use default value so psalm will not ask to use all 3 parameters.
2021-01-29 11:47:14 +01:00
Matt Brown
6f598464a9
Mixed array access should mark vars as used just in case
2021-01-29 11:47:14 +01:00
Matt Brown
dd20e838ce
Make more try vars potentially undefined
...
Fixes #4764
2021-01-29 11:47:14 +01:00
Matt Brown
ba1a076059
Fix interface property regression
2021-01-29 11:47:13 +01:00
Matt Brown
eba91f741b
Fix #4760 - prevent unpacked vars from breaking call when checking unitialised properties
2021-01-29 11:47:13 +01:00
Matt Brown
9c5cc02f90
Fix #4759 – don’t generate assertion when assigning to same-named variable
2021-01-29 11:47:13 +01:00
Jáchym Toušek
fcf2bc3831
Fix Ds\Sequence::toArray() return type ( #4763 )
2021-01-29 11:47:13 +01:00
Benjamin Morel
8990f1ec95
Fix ImagickPixel::getColor() ( #4758 )
2021-01-29 11:47:13 +01:00
Denis Smetannikov
0882d563fa
Update ExistingAtomicStaticCallAnalyzer.php ( #4761 )
...
The invalid syntax for PHP 7.1+
2021-01-29 11:47:13 +01:00
Matt Brown
74b8198cb4
Simplify FunctionLikeDocblockScanner
2021-01-29 11:47:13 +01:00
Matt Brown
17d9db089f
Break apart AtomicPropertyFetchAnalyzer::analyze
2021-01-29 11:47:13 +01:00
Matt Brown
18c9b264bb
Simplify AssertionReconciler
2021-01-29 11:47:12 +01:00
Matt Brown
febec21f34
Improve message
2021-01-29 11:47:12 +01:00
Benjamin Morel
1c14600c03
Improve Imagick call map ( #4757 )
2021-01-29 11:47:12 +01:00
Matt Brown
1780541501
Ref #4753 - allow int literals to inform key type
2021-01-29 11:47:12 +01:00
Matt Brown
a20db1ce34
Fix #4751 - allow MethodSignatureMismatch to be overridable when info comes from docblock
2021-01-29 11:47:12 +01:00
Matt Brown
c54416090f
Don’t suggest a potential value that’s undefined
...
Fixes #4754
2021-01-29 11:47:12 +01:00