Matthew Brown
86a89b2d27
Fix #3034 - expand out while expressions for more accurate variable initialisation
2020-03-28 18:22:08 -04:00
Matthew Brown
de6aee32d1
Fix #3035 - improve templating for property assignments
2020-03-28 17:18:21 -04:00
Matthew Brown
47c1470e3b
Refactor reference checks to use more appropriate properties
2020-03-28 16:30:56 -04:00
Matthew Brown
3edf31c885
Fix test
2020-03-28 15:00:27 -04:00
Brown
e3ff856cac
Improve treatment of static in intersection
2020-03-27 19:17:44 -04:00
Brown
056f4aaac6
Fix #3027 - inherited properties should be templated properly
2020-03-27 18:31:48 -04:00
Brown
ae31ec6805
Fix resolution of get_called_class
2020-03-27 09:51:53 -04:00
Brown
031c5be8e6
Check trait methods better
2020-03-27 00:37:33 -04:00
Brown
971ae50bea
Do prep work for #3024 - improve handling of absent class references
2020-03-26 12:35:27 -04:00
Matthew Brown
68c95c622a
Save information about last runs whether or not there were errors
2020-03-26 00:46:39 -04:00
Matthew Brown
f94ab22a5f
Be better about strict inference
2020-03-25 09:18:49 -04:00
Matthew Brown
4734583444
Don’t overwrite already-defined template
2020-03-24 23:40:01 -04:00
Brown
467da32f84
Fix instanceof static and isa (static::class) handling
2020-03-24 18:58:15 -04:00
iggyvolz
94b246b987
Initial commit ( #3013 )
2020-03-24 18:32:57 -04:00
Brown
a9b6c51748
Improve new $class to make it more static-y
2020-03-24 18:30:08 -04:00
Brown
1bfc61d402
Allow final classes to bypass static checks
2020-03-24 18:14:10 -04:00
Brown
ec34a16291
Warn about invalid static returns
2020-03-24 18:00:20 -04:00
Brown
f6759c3d16
Check return statement types for inherited docblocks
2020-03-24 17:59:48 -04:00
Brown
cae15b6c62
Use appropriate template types when applying array_filter asssertions
...
Fixes #3008
2020-03-24 12:15:56 -04:00
Brown
25bd2ed5fb
Fix #3010 - prevent false-negative after calling isset on possibly-false array
2020-03-24 12:01:39 -04:00
Matthew Brown
27a0651b6c
Fix #3009 - make sure return type is set when returning early
2020-03-23 13:25:55 -04:00
Brown
4c081f7835
Things with mixed values can be the same
2020-03-23 12:08:05 -04:00
Matthew Brown
6058725256
Add prototype for conditional return type
2020-03-22 10:44:48 -04:00
Matthew Brown
6746f1c047
Fix #3004 - reset property types inside a closure defined in a class
2020-03-21 20:46:38 -04:00
Matthew Brown
c986cdf12e
Allow edge-case of by-reference assignment with unitiliazed property
...
Fixes #3003
2020-03-21 19:23:32 -04:00
Matthew Brown
51f92dd1e5
Don’t add php tag unnecessarily
2020-03-20 19:15:06 -04:00
Matthew Brown
4e07dfebaa
Make link part of IssueData so it’s available to all consumers
2020-03-19 16:22:43 -04:00
Matthew Brown
7ba0d27d6c
Fix formatting
2020-03-19 12:42:41 -04:00
Matthew Brown
2f62e2d9f5
Move issues to separate pages
2020-03-19 12:32:49 -04:00
Matthew Brown
cbf139952c
Fix #2989 - delay @mixin hydration until parent methods inherited
2020-03-18 21:38:53 -04:00
Matthew Brown
f7907eb43f
Fix #2987 - ignore MixedReturnTypeCoercion for generator send param
2020-03-18 21:25:25 -04:00
Matthew Brown
311bd19a6a
Fix #2983 - inherited lists should have their template types localised
2020-03-18 16:23:09 -04:00
Pavel Batečko
48af534270
Improve parse_url() return type ( #2955 )
2020-03-18 15:17:24 -04:00
Matthew Brown
9cd817077e
Improve fix
2020-03-17 17:34:45 -04:00
Matthew Brown
4166e5a4ef
Fix tests
2020-03-17 16:30:03 -04:00
Matthew Brown
da170efb65
Don’t coerce literal values
...
Fixes #2982
2020-03-17 16:16:58 -04:00
Matthew Brown
9556e9ad69
Disable enclosing method/function return type inference
...
cc @ragboyjr – this makes Psalm unstable, as method return types cannot change midway through analysis (as it means results would be dependent on file analysis order)
2020-03-16 11:45:49 -04:00
Matthew Brown
a8a1142889
Fix #2977 - make MixedAssignment message a bit more clear, hopefully
2020-03-15 23:20:12 -04:00
Matthew Brown
c85fa9083d
Fix #2915 - prevent "if (true)" and similar
2020-03-15 22:23:31 -04:00
Matthew Brown
50eb12e562
Fix implementation kink
2020-03-15 16:14:09 -04:00
Matthew Brown
532ce576cc
Fix #2974 - interpret interfaces a little better
2020-03-15 15:49:13 -04:00
Matthew Brown
b6380ae595
Fix false-positives around unevaluated code
2020-03-15 14:43:05 -04:00
Matthew Brown
6c7f89b0ab
Fix #2920 - track unevaluated code after nested returns
2020-03-15 14:31:41 -04:00
Matthew Brown
3ebb5a1142
Fix #1843 - ignore intersection TooManyArguments issues
2020-03-15 14:01:33 -04:00
Matthew Brown
0022de1f13
Fix #946 - allow too many arguments when one of union agrees
2020-03-15 13:44:00 -04:00
Matthew Brown
0af2eba4b9
Fix #2973 - don’t allow template type through
2020-03-15 11:14:06 -04:00
Matthew Brown
2c0cf4030f
Detect assigning collections of mutable objects in immutable
...
Fixes #2946
2020-03-15 00:21:20 -04:00
Matthew Brown
43189b3d55
Allow types to be traversed
2020-03-14 23:54:51 -04:00
RJ Garcia
2de3e27f10
Initial inferred Closure Returns ( #2945 )
...
- Added detection for when we can infer
closure types from parent fn return types
- Implemented functionality for infering types of
returned closures
- Added ability to infer type of return from typed
closures
- Added a new getFunctionLikeStorage method in
Codebase to support easily getting a function
despite being a method, closure, or function
- Added some utilities to the MethodIdentifier
to facilitate creating MethodIdentifier's from
string method references
Closes #2896
Signed-off-by: RJ Garcia <rj@bighead.net>
2020-03-14 14:51:43 -04:00
RJ Garcia
5a008fe1e6
Tests for TypeAnalyzer::isContainedBy on classes ( #2971 )
...
- Added additional tests to showcase subtyping
Signed-off-by: RJ Garcia <rj@bighead.net>
2020-03-14 14:48:45 -04:00