1
0
mirror of https://github.com/danog/psalm.git synced 2024-12-15 19:07:00 +01:00
Commit Graph

146 Commits

Author SHA1 Message Date
Brown
aa3846758e Fix #3153 - narrow template types in conditional branches 2020-04-17 09:53:58 -04:00
Brown
633b210a32 Fix test 2020-04-12 21:47:50 -04:00
Matthew Brown
6cea065bca Attempt to export file order in Linux CI 2020-04-05 00:10:50 -04:00
Matthew Brown
4c52032491 Use mixed if yield type not known 2020-04-04 23:54:41 -04:00
Matthew Brown
120595f480 Clone a little earlier 2020-04-04 23:45:38 -04:00
Brown
08594cf712 Always be cloning 2020-04-03 13:56:03 -04:00
Brown
af4a7cabe9 Fix #3057 and add support for @psalm-yield annotation 2020-04-02 22:38:10 -04:00
Matthew Brown
194f02507d Allow conditional types to reference class constants 2020-03-29 13:37:37 -04:00
Matthew Brown
788da0680e Allow var_export userland implementation 2020-03-29 10:19:09 -04:00
Matthew Brown
47c1470e3b Refactor reference checks to use more appropriate properties 2020-03-28 16:30:56 -04:00
Brown
60613462fe Improve static resolution a little more 2020-03-28 08:14:35 -04:00
Brown
5835c34a29 Expand out static extra types 2020-03-28 00:08:31 -04:00
Brown
e3ff856cac Improve treatment of static in intersection 2020-03-27 19:17:44 -04:00
Brown
971ae50bea Do prep work for #3024 - improve handling of absent class references 2020-03-26 12:35:27 -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
Matthew Brown
26694345d6 Fix unknown variable 2020-03-21 20:53:46 -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
9cd817077e Improve fix 2020-03-17 17:34:45 -04:00
Matthew Brown
43189b3d55 Allow types to be traversed 2020-03-14 23:54:51 -04:00
Matthew Brown
0aca01faea Improve fix to #2805 2020-03-14 01:09:12 -04:00
Matthew Brown
bfb919d26a Break out methods into their own classes 2020-03-11 23:04:52 -04:00
Matthew Brown
f128c8ffda Fix overriding of mapped property type visibility 2020-03-11 17:41:05 -04:00
Brown
0cfe565d0a Fix #2952 - always be cloning 2020-03-09 18:59:56 -04:00
Matthew Brown
5b7ab6a542 Fix coercion 2020-03-09 01:32:27 -04:00
Matthew Brown
3243819f1b Fix #2941 - allow class-string<self> to be fleshed out 2020-03-09 01:29:16 -04:00
Brown
292a2359b3 Add slash 2020-02-21 15:44:26 -05:00
Brown
b51863fc9b Fix #2848 - allow casting templated types 2020-02-21 15:17:35 -05:00
Matthew Brown
3561c7d5dc Make sure yield from expressions counted as used
Fixes #2823
2020-02-17 19:21:04 -05:00
Matthew Brown
cf977c3542 Don’t convert constant descriptions to lowercase 2020-02-17 18:19:33 -05:00
Matthew Brown
653353709a Use MethodIdentifier object instead of string 2020-02-14 20:54:26 -05:00
Brown
f141f7c526 Improve --diff checks by including trait-using classes in dependents 2020-02-11 16:39:33 -05:00
Brown
dcc855de95 Fix #2739 - specify wildcards in constants 2020-02-07 10:54:57 -05:00
Matthew Brown
5eb2ebc508 Add more type-system protections for bad array args 2020-01-29 23:41:17 -05:00
Matthew Brown
989123f82e Fix line length 2020-01-29 22:31:23 -05:00
Matthew Brown
933dff9e20 Fix #2712 - allow __toString to have more specific type 2020-01-29 22:28:40 -05:00
Brown
e68ca6a20b Fix #2661 - catch invalid array_push on property 2020-01-22 09:57:59 -05:00
Matthew Brown
85966d8a21 Fix #2577 - fix list cast to array 2020-01-11 11:42:09 -05:00
Brown
bd9142f131 Fix #2574 - remove assertions after increment 2020-01-09 11:51:56 -05:00
SignpostMarv
fbf66ba7f6 Typecast bool to int (#2550)
* adding specific checks for typecasting booleans, re: vimeo/psalm#2548

* satisfying phpcs

* amend check to use psalm types rather than php-parser types

* implementing tests for typecasting bools to int

* satisfying phpcs
2020-01-04 16:36:19 -05:00
Matthew Brown
9fa2db1b6c Move Union::getTypes to Union::getAtomicTypes 2020-01-04 12:20:26 -05:00
Matthew Brown
55c2f7faa2 Fix #2508 - don’t replace templated types with generic ones inside own function 2019-12-28 18:38:02 -05:00
Matthew Brown
734ad02203 Fix #2476 - flesh out iterable params 2019-12-18 17:19:54 +00:00
Matthew Brown
bf67c036aa Fix #2474 - treat free-standing binaryops as ifs instead 2019-12-16 08:32:00 -05:00
Brown
6d02aa86e8 Reconcile string emptiness a bit better 2019-12-13 15:51:54 -05:00
Matthew Brown
f45014d403 Fix #2460 - allow assertions on immutable method calls 2019-12-12 09:32:33 -05:00
Brown
b3cf9d3958 Catch circular references in constants
Fixes #2453
2019-12-10 16:16:44 -05:00
Brown
b78acf796f Fix #2445 - only generalise param when it’s generic 2019-12-09 10:58:09 -05:00
Matthew Brown
2e00ad2240 Treat more things as assignments 2019-12-07 15:58:05 -05:00
Brown
e1dd22ef6c Allow static::class to be used in array assertions 2019-12-04 12:23:26 -05:00