1
0
mirror of https://github.com/danog/psalm.git synced 2024-12-12 17:27:28 +01:00
Commit Graph

7659 Commits

Author SHA1 Message Date
orklah
5b7e525272
ambiguous php version checks (#4331) 2020-10-14 20:00:50 -04:00
Marco Perone
641e7d7008
add documentation for pure-callable (#4329) 2020-10-14 19:59:44 -04:00
Marco Perone
ece18cd9b5
provide documentation for ensureArrayIntOffsetsExist configuration option (#4328) 2020-10-14 19:59:28 -04:00
Marcus Bointon
e172e88274
Fix preg_match_all stub (#4325)
* preg_match_all can return false

* Test for preg_match_all returning false

* Fix test

* Add @psalm-ignore-falsable-return
2020-10-14 19:59:07 -04:00
Matt Brown
b2382cdf18 Use correct count 2020-10-14 18:56:49 -04:00
Matt Brown
4488d5fb1f Use more accurate arguments count 2020-10-14 18:51:15 -04:00
Matt Brown
864a7bbb4c Add better support for get_debug_type 2020-10-14 17:30:08 -04:00
Matt Brown
a0fbac347e Prevent features pre-php-8 2020-10-14 17:09:56 -04:00
Matt Brown
e29cbe368a Support false and null unions in PHP 8 signatures 2020-10-14 15:24:37 -04:00
Matt Brown
62c15b2a4f Avoid crash when callable type is missing 2020-10-14 11:01:46 -04:00
Matt Brown
724b25b918 Change control_flow_graph to data_flow_graph 2020-10-13 17:28:12 -04:00
Matt Brown
516141a380 Rename ControlFlowGraph to more appropriate DataFlowGraph 2020-10-13 16:49:03 -04:00
Pol Dellaiera
446a833d18
CachingIterator - Add forgotten constructor parameter. (#4322)
Signed-off-by: Pol Dellaiera <pol.dellaiera@protonmail.com>
2020-10-13 11:48:37 -04:00
Pol Dellaiera
31c924c314
Add more standard iterators (#4320)
* Add CachingIterator, LimitIterator, InfiniteIterator, CallbackFilterIterator, NoRewindIterator.

Signed-off-by: Pol Dellaiera <pol.dellaiera@protonmail.com>

* Add related Iterator tests.

Signed-off-by: Pol Dellaiera <pol.dellaiera@protonmail.com>
2020-10-13 11:35:49 -04:00
Matt Brown
1ae9a6127e Fix #4315 - prevent crash when setting unknown property in finally 2020-10-13 08:32:26 -04:00
Matt Brown
bb7d7132f7 Do arithmetic for preg_split arguments 2020-10-12 20:26:02 -04:00
Matt Brown
2ac2da6079 Improve preg_split return more 2020-10-12 19:16:48 -04:00
Matt Brown
b08d70f977 Fix #4252 - fix xml generation 2020-10-12 18:39:26 -04:00
orklah
62e79fb7ea
param types (#4313) 2020-10-12 15:46:47 -04:00
Matt Brown
08586c47c1 Remove deleted path 2020-10-12 15:17:22 -04:00
Matt Brown
fee3b63122 Fix #4274 - don’t ignore mixed union in array_shift operation 2020-10-12 15:17:22 -04:00
orklah
10f2966dcb
return types (#4311)
* return types

* remove willReturn for void methods
2020-10-12 15:02:52 -04:00
Matt Brown
fcfa746ba8 Fix #4310 - prevent literal class check on union 2020-10-12 14:45:11 -04:00
Matt Brown
d16c0de872 Add slash 2020-10-12 14:32:44 -04:00
Matt Brown
464795d86c Fix #4309 - improve reuse of callmap callable inference 2020-10-12 13:46:43 -04:00
Matt Brown
f83b50460a Add better return type for preg_split 2020-10-12 13:04:28 -04:00
Matt Brown
5743471a19 Don’t merge array and Traversable to iterable when there are intersections 2020-10-12 12:45:31 -04:00
Matt Brown
ce90466ad4 Change name to arraylike-object 2020-10-12 12:39:48 -04:00
Matt Brown
8319278ef1 4.x - Add support for array-like-object
Ref #4308
2020-10-12 12:32:02 -04:00
Matt Brown
d8a74ca383 4.x - Prevent passing empty array to max or min 2020-10-12 12:09:12 -04:00
Matt Brown
7cf6495461 4.x - skip Stringable test if not in PHP 8.0 2020-10-12 11:35:14 -04:00
Matt Brown
5c2591f7b0 Make docblocks compatible with PHP 8 2020-10-12 11:21:53 -04:00
Matt Brown
eeacec315a 4.x - fix callmap regressions 2020-10-12 10:08:15 -04:00
Matt Brown
7e65355513 4.x - detect falty !is_resource checks 2020-10-12 09:57:11 -04:00
Matt Brown
b85cbd01a7 4.x - add support for PHP 8 callmap 2020-10-12 09:41:25 -04:00
Matt Brown
903d7f3601 Add more fixes 2020-10-12 08:26:17 -04:00
Matt Brown
321b81e1f0 Fix order 2020-10-12 02:00:03 -04:00
Matt Brown
c9954b34f6 Add changes from PHPStan‘s functionmap 2020-10-12 01:56:04 -04:00
Matt Brown
f3b05f5ab5 Move static code out of src 2020-10-12 00:59:19 -04:00
Matt Brown
5be7276a17 Fix #4306 - negating positive-numeric is useless, avoid crash 2020-10-11 23:16:43 -04:00
Matt Brown
7195275993 Fix #4299 - only allow unpacking for the zeroeth-indexed element 2020-10-08 09:51:27 -04:00
Matt Brown
e9b520d72d Ignore precondition issues in loop 2020-10-07 20:24:50 -04:00
Matt Brown
3b19913b44 Unbreak CI 2020-10-07 18:50:30 -04:00
Matt Brown
a9c145a725 Convert numeric literal strings to their int/float equivalents for numeric operations 2020-10-07 18:06:41 -04:00
Matt Brown
443025eab8 Fix addition of int and string type 2020-10-07 18:01:41 -04:00
Matt Brown
8b7657f379 Fix #4297 - use correct property id for each different MissingConstructor error 2020-10-07 17:54:00 -04:00
Matt Brown
1f2d2764ab Fix #4287 - intersection of regular arrays should not result in crash 2020-10-07 17:47:17 -04:00
Matt Brown
c8d4bafb85 Improve accuracy of messages 2020-10-07 17:26:37 -04:00
Matt Brown
c2108e89db Warn about impossible/redundant conditions in RHS of || 2020-10-07 17:04:01 -04:00
Matt Brown
595b8178e0 Improve error message 2020-10-07 15:36:31 -04:00