Brown
2968b3b065
Add to StatementsAnalyzer taint object instead of Context
2020-09-20 18:42:21 -04:00
Brown
abb9502921
Rename Taint object to TaintGraph
2020-09-20 18:27:02 -04:00
orklah
de16308f2e
useless comparison ( #4223 )
...
* remove unused code
* fix wrong fix
2020-09-20 13:01:27 -04:00
orklah
7093253eea
fix test on windows ( #4225 )
2020-09-20 13:00:30 -04:00
Brown
cf8dcc163e
Use shuffled files
2020-09-20 12:59:32 -04:00
orklah
24a38f21ce
Use array destructuring when possible ( #4221 )
...
* list usage
* fix inversion
2020-09-20 12:55:38 -04:00
orklah
b4bfbb6a28
remove incorrect inheritDoc ( #4220 )
2020-09-20 12:55:10 -04:00
orklah
1a1b88bb5e
add visibilities to constants ( #4219 )
2020-09-20 12:54:46 -04:00
Brown
ef3cf67f50
Fix #4198 - make analysis of class-string property assignments more robust
2020-09-20 09:18:35 -04:00
orklah
cb7065ae07
replace deprecated methods with their equivalent ( #4217 )
2020-09-20 08:56:49 -04:00
orklah
a9a364e363
Misc improvements ( #4216 )
...
* misc changes
* fix CI
2020-09-20 08:55:28 -04:00
orklah
b19f0a7034
Remove empty() and use strict comparison when safe ( #4211 )
...
* replace empty usage with stricter checks
* use strict comparison when safe
* replace is_null with === null for consistency
2020-09-19 18:26:51 -04:00
Brown
1ac527bbf1
Meke staticy methods properly static
2020-09-19 18:24:36 -04:00
Brown
62d43817f6
Fix #4206 - add shortcut for if ((bool) $foo)
2020-09-19 18:15:12 -04:00
Brown
0ae436d335
Fix a couple of false-positive redundant conditions
2020-09-19 18:12:14 -04:00
Brown
941643ca59
Fix tests
2020-09-19 17:04:35 -04:00
Brown
72d1d799b1
Fix #4208 - array with possibly-undefined keys isn‘t really sealed
2020-09-19 15:46:54 -04:00
Brown
f973937aec
Fix #4209 - allow hinting arrow function return type
2020-09-19 14:59:19 -04:00
Brown
a8a2a4cb66
Fix #4210 - fix __invoke declaration tracing
2020-09-19 14:18:52 -04:00
Brown
94ed53b25a
func_num_args is pure
...
fixes #4215
2020-09-19 13:58:29 -04:00
orklah
5db75dfbf2
align default value with documentation ( #4188 )
2020-09-17 21:40:19 -04:00
Brown
363887a445
Add explicit offset
...
Fixes #4202
2020-09-17 21:35:30 -04:00
Daniel Badura
7d5dbd3f38
add random_int as stub, returns positive-int if min is positive-int ( #4199 )
2020-09-17 08:31:31 -04:00
orklah
191495328a
Fix errors in return types ( #4189 )
...
* FunctionLikeAnalyzer::verifyReturnType returns void
* ArrayFunctionArgumentsAnalyzer::checkArgumentsMatch returns void
* AssertionFinder::scrapeAssertions can't return null
2020-09-16 17:35:55 -04:00
Brown
dda013dc2e
Only refine for matching closure union members
...
Ref #4136
2020-09-15 09:40:27 -04:00
Brown
0b209864fe
Improve accuracy of array_filter
2020-09-14 13:31:53 -04:00
Brown
8d7fe83e2a
Improve array_merge return type
2020-09-14 13:06:15 -04:00
Brown
b10c1ac280
Fix style
2020-09-14 12:19:30 -04:00
Brown
1f3215d36b
Support more array intersections in type parsing
2020-09-14 12:13:33 -04:00
Brown
02b725f8a2
Add back suppression
2020-09-14 11:02:04 -04:00
Brown
a37a3c5c96
Make sure all written entries are correctly sorted
2020-09-14 11:00:15 -04:00
Brown
17a0ecb60e
Fix regression – detect unused params with defaults again
2020-09-14 10:58:36 -04:00
Brown
1df3c9365c
Fix template check
2020-09-14 10:00:09 -04:00
Brown
79f4e9c354
Do no writing when saving parser cache in tests
2020-09-14 09:56:39 -04:00
Brown
77e84b3817
Fix a few more things
2020-09-13 23:28:31 -04:00
Brown
c4450b930c
Fix various things
2020-09-13 22:39:03 -04:00
Brown
3f911662f7
Fix stub test
2020-09-13 22:13:39 -04:00
Brown
249903e18a
Fix style issues
2020-09-13 21:45:07 -04:00
Brown
56bae3b587
Add check for strpos dictionaries
...
Ref #4070
2020-09-13 21:42:44 -04:00
Brown
8f8dbfbd72
Fix #4122 - detect yield in function arguments
2020-09-13 17:13:26 -04:00
Brown
f180fb23bc
Fix #4178 - always detect missing property types
2020-09-13 16:50:50 -04:00
Bruce Weirdan
689027c92d
Support multiple issue types in @psalm-suppress
( #4179 )
...
* Accept multiple issue names in `@psalm-suppress`
Fixes vimeo/psalm#1575
* Accept multiple issue types on statement docblocks as well
* Proper highlighting of individual issues in compound suppressions
2020-09-13 16:41:14 -04:00
Bruce Weirdan
cd110c7e2f
Added @psalm-stub-override
for classlikes and methods ( #4177 )
...
Fixes vimeo/psalm#1252
2020-09-13 16:40:31 -04:00
orklah
da47588f91
replace return;
by return null;
in every non-void method, add return null;
when mising, add return types, remove redundant phpdoc ( #4176 )
2020-09-13 16:39:06 -04:00
Brown
ded9237176
Fix bad error flagging
2020-09-13 16:38:32 -04:00
Brown
9ed09d2679
Fix #4127 - improve error message for unused closure var
2020-09-12 17:03:11 -04:00
ygottschalk
5b0c9b1a28
added array-size max constraint to greater check ( #4175 )
...
added a few unit tests
2020-09-12 16:13:13 -04:00
Brown
09d22cb05c
Fix #4169 - add appropriate bounds check
2020-09-12 11:33:26 -04:00
Claas Augner
3f8c91a64e
fix(docs): add missing issues to error levels ( #4171 )
2020-09-12 11:25:41 -04:00
Toshiyuki Goto
ad437c5265
Workaround to PhpScoper group use bug in Box ( #4174 )
2020-09-12 11:24:40 -04:00