1
0
mirror of https://github.com/danog/psalm.git synced 2024-12-14 18:36:58 +01:00
Commit Graph

589 Commits

Author SHA1 Message Date
Matthew Brown
975ff9250b Fix #2328 - don’t crash on unexpected divider 2019-11-13 01:13:29 -05:00
Matthew Brown
2fc7f5fdf7 Fix #1830 - infer key type after array_key_exists check 2019-11-10 14:23:53 -05:00
Brown
ac6256e645 Fix #2312, improve understanding of template replacement 2019-11-08 11:56:41 -05:00
Brown
3d7b34e7f6 Fix #2273 - ensure all template params are bound 2019-11-07 11:03:41 -05:00
Brown
a8ed6ba9c4 Fix #2308 - prevent specialisation from bound params 2019-11-06 11:20:51 -05:00
Brown
e7330afe8b Fix #2295 - support special case of array_shift on known offset type 2019-11-04 09:21:13 -05:00
Matthew Brown
8f421dc0bb Refactor template calculation out from Psalm\Type\Union 2019-11-03 21:27:40 -05:00
Matthew Brown
a82e35a59f Fix #2291 - extended covariant template param types should be treated as covariant 2019-11-01 18:25:07 +01:00
Matthew Brown
bab7e46983 Fix #2281 - allow lists to accept list types 2019-11-01 13:35:16 +00:00
Matthew Brown
8d7cdeb8ec Fix #2275 - allow extended templated types to bypass mixed type coercion rules 2019-10-29 10:07:34 +00:00
Brown
8876499ddd Fix #2252 - allow destructuring of ArrayAccess objects 2019-10-22 11:17:42 -04:00
Matthew Brown
1d6ca9bd7d Allow callable-array type in docblocks 2019-10-20 15:33:57 -04:00
lhchavez
216f991b0c Normalize stringified type names (#2239)
This change makes stringified types more normalized. Concretely it sorts
all union types, reconciled types, and sorts the keys within object-like
types.
2019-10-17 01:14:33 -04:00
Matthew Brown
7b522af169 Provide necessary typehint 2019-10-15 20:41:06 -04:00
Matthew Brown
0556f28a9f Fix #2224 - make sure literal strings are put into appropriate arrays when templating 2019-10-10 23:38:57 -04:00
Brown
99c91efbc6 Add support for reconciling callable lists 2019-10-10 10:34:31 -04:00
Brown
b75720c32b Add more list types 2019-10-09 10:04:34 -04:00
Brown
0b0534d41b Add more list annotations to Psalm’s codebase 2019-10-09 09:17:43 -04:00
Matthew Brown
e620c2cfa4 Fix issue creating empty array offsets 2019-10-08 21:23:16 -04:00
Brown
16c33d1565 Add support for list type
Fixes #2209
2019-10-08 18:44:46 -04:00
Brown
c7eff18481 Add basic type classes for TList 2019-10-08 18:43:54 -04:00
Brown
f175050837 Fix #2214 - use better way for marking types as changed 2019-10-07 16:59:05 -04:00
Brown
94001aad4a Fix #2208 - handle templated property types appropriately 2019-10-04 13:51:36 -04:00
Brown
b0aaede9e1 Add support for checking integer array offsets 2019-10-04 11:08:08 -04:00
Matthew Brown
d85fbaec09 Add stricter checks after first isset 2019-10-03 21:34:56 -04:00
Brown
60214ab0c7 Allow assertions on arbitrary offsets without isset 2019-10-03 18:40:47 -04:00
Brown
ca06277f30 Add better support for previous key types 2019-10-03 15:43:17 -04:00
Brown
9b31483018 Fix unused var 2019-10-02 09:35:22 -04:00
Matthew Brown
24977fb021 Fix small bug 2019-10-02 01:17:45 -04:00
Brown
d225374d6d Fix #2156 - do better inference after isset 2019-10-01 19:31:08 -04:00
Brown
a81c3067ad Store the whole type 2019-10-01 17:09:32 -04:00
Matthew Brown
a9d0296252 Fix #2182 - allow modification to cloned objects inside 2019-09-30 22:07:20 -04:00
Matthew Brown
81464d8dbf Fix #2179 - add gz* to list of impure functions 2019-09-27 09:50:33 -04:00
Matthew Brown
a5f79353ed Fix #2157 - don’t merge closures and callable params 2019-09-22 00:58:30 -04:00
Matthew Brown
9ad6c36d9b
Conditionally verify that array offsets exist (#2147)
* Check array offsets idea

* Clean up some issues

* Add a few light fixes

* Add docs
2019-09-18 14:21:06 -04:00
Matthew Brown
0b4981f01b Fix #1551 - do better at inferring class constant types 2019-09-14 14:26:31 -04:00
Brown
a6baa2d04c Allow callables to be understood as pure
Fixes #2112
2019-09-09 12:11:04 -04:00
Matthew Brown
662f094886 Don’t complain about deprecated class inside itself 2019-09-08 14:55:45 -04:00
Matthew Brown
e7a69f715d Fix #2106 - add defining class to converted template 2019-09-07 13:44:47 -04:00
Matthew Brown
900cfc0f05 Improve handling of external-mutation-free objects created in pure functions 2019-08-31 09:49:32 -04:00
Brown
aba3659311 Add more specific key coercion rules when assigning to arrays 2019-08-27 15:12:25 -04:00
Brown
5a5629b835 Mixed value object-likes should still have string keys 2019-08-27 14:40:40 -04:00
Brown
4fcbc0fdad Fix #2028 - warn when using deprecated class in function signature 2019-08-22 11:25:13 -04:00
Brown
855ab359fe Break up Atomic::check 2019-08-22 11:25:13 -04:00
Matthew Brown
920c2d83c3 Use types for method_exists checks in some places 2019-08-18 22:27:19 -04:00
Matthew Brown
9d62971006 Fix possible issue negating falsy assertion 2019-08-18 17:51:43 -04:00
Matthew Brown
c5f62d261d Remove redundant @psalm-suppress in Psalm’s codebsae 2019-08-18 16:10:12 -04:00
Brown
43041836dd Fix #2026 - add support for calling __toString implicitly after method_exists 2019-08-16 11:33:58 -04:00
Matthew Brown
600999a3a8 Add better typing 2019-08-14 00:47:57 -04:00
Matthew Brown
d5b026839c Add support for different taint types ref #1990 2019-08-12 23:16:05 -04:00