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

11308 Commits

Author SHA1 Message Date
orklah
80f972cc38
Merge pull request #7791 from ohader/issue-7771-4x
Avoid json_encode when serializing non-UTF8 literals
2022-03-16 19:00:49 +01:00
Oliver Hader
9e4e468907
Adjust test case format
Related: #7771
2022-03-16 10:35:36 +01:00
Matthew Brown
a9f4148db2 Rename referenced_var_ids to cond_referenced_var_ids
Also reduce usage — this was a holdover of the old way of tracking unused variables
2022-03-15 18:40:31 -04:00
orklah
ebffd5258a
Merge pull request #7433 from zoonru/maximum_shaped_array_size
Add configuration for maximum size of shaped array
2022-03-15 21:19:05 +01:00
e7ec124ebb
Add documentation for maxStringLength and maxShapedArraySize configs 2022-03-15 11:05:57 +01:00
Oliver Hader
2b3753676b
Avoid json_encode when serializing non-UTF8 literals
`\Psalm\Internal\Clause::$hash` basically holds a hash on
arbitrary input literals, used for later comparison. Using
`json_encode` fails when dealing with non-UTF8 literals,
which has been replaced by plain PHP `serialize`.

Resolves: #7771
2022-03-15 10:39:58 +01:00
Oliver Hader
b00d9e9514
Add test case reproducing issue #7771
Related: #7771
2022-03-15 10:34:46 +01:00
d4170feb0f
Add documentation for maxStringLength and maxShapedArraySize configs 2022-03-15 10:14:36 +01:00
orklah
32f10c392d
Merge pull request #7788 from AndrolGenhald/attribute-analysis-improvements
More attribute fixes.
2022-03-14 21:11:19 +01:00
AndrolGenhald
11f51f4c54 Use key-of instead of literal int union. 2022-03-14 15:05:33 -05:00
orklah
05d253b704
Merge pull request #7785 from hc-jworman/#7784_PDOStatement_fetchAll()_has_incorrect_type
PDOStatement::fetchAll() has incorrect type
2022-03-14 20:21:59 +01:00
AndrolGenhald
08d4d797ef More attribute fixes. 2022-03-14 14:15:07 -05:00
orklah
83c534414e
Merge pull request #7787 from orklah/callable-string
restore callable-string Id
2022-03-14 20:11:56 +01:00
Jack Worman
88f9e19acd #7784 PDOStatement::fetchAll() has incorrect type 2022-03-14 14:11:31 -05:00
orklah
d1ce74bc79 fix name 2022-03-14 20:07:03 +01:00
Jack Worman
0ab947024b #7784 PDOStatement::fetchAll() has incorrect type 2022-03-14 13:33:29 -05:00
Matthew Brown
a9ccfd3da4 Fix test with sort 2022-03-14 13:02:55 -04:00
Matthew Brown
e578413d3f Calculate upper bound ahead of time
This prevents generating large numbers of clauses we'll have to ignore anyway
2022-03-14 11:32:51 -04:00
Matthew Brown
77f47ede92 Remove ref to unused function 2022-03-14 10:40:46 -04:00
Matthew Brown
040122403d Clause sort should be normal, not reversed 2022-03-14 10:38:42 -04:00
orklah
7cfb601ab8
Merge pull request #7718 from niconoe-/fix-3036
Fix #3036: make argument $read of internal PHP function stream_socket nullable.
2022-03-13 16:16:35 +01:00
Matthew Brown
8d5664d539 Remove unused line 2022-03-12 23:23:46 -05:00
Matthew Brown
76119237cc Fix #7776
When a new clause contains tautology it can be disregarded entirely
2022-03-12 23:21:42 -05:00
Matthew Brown
64d7792479 Fix too-long line 2022-03-12 22:37:06 -05:00
Matthew Brown
9c8e088917 Fix style 2022-03-12 22:33:58 -05:00
Matthew Brown
ed4782e0e0 Improve performance of large formula operations 2022-03-12 22:31:12 -05:00
orklah
c1ad5f6be0
Merge pull request #7775 from fluffycondor/improve-int-range-parsing
Improve int range parsing
2022-03-12 08:27:23 +01:00
Matthew Brown
427eecdcd8 Remove unnecessary switch statement code 2022-03-11 22:02:55 -05:00
fluffycondor
7240f01154
Code style 2022-03-11 23:02:11 +00:00
fluffycondor
cb5231463c
Make error message more verbose 2022-03-11 22:58:41 +00:00
fluffycondor
6bc90fa0a9
Fix error messages 2022-03-11 22:54:30 +00:00
Semyon
9beb0a62b2 Forbid min bound greater than max bound in int range 2022-03-11 17:26:59 +03:00
Semyon
a7e98f4bfc Forbid any non literal int in int range (except min and max named objects) 2022-03-11 17:26:07 +03:00
Nicolas Giraud
cf1f375f24 Remove useless array casting as CallMap for stream_select is reset. 2022-03-11 08:58:17 +01:00
Nicolas Giraud
0dc435409c Replace changes in the CallMap for stream_select by a stub. 2022-03-11 08:52:36 +01:00
Matthew Brown
a0739b1716 Abandon humbug/box update attempt 2022-03-07 16:57:18 -05:00
Matthew Brown
510456c7c4 Improve scoping a bit more 2022-03-07 16:50:20 -05:00
Matthew Brown
f0b214265c Remove slash 2022-03-07 16:09:03 -05:00
Matthew Brown
2a9ea7ea71 Support Stringable before PhpToken autoloading 2022-03-07 16:08:24 -05:00
Matthew Brown
4311386122 Add a bunch of necessary fixes to get phar scoping working on PHP 7.4 2022-03-07 16:06:38 -05:00
Matthew Brown
50565c658a Fix scoping of polyfill 2022-03-07 15:40:56 -05:00
Matthew Brown
3dfe31b334 Fix path once more 2022-03-07 15:37:22 -05:00
Matthew Brown
03cd1c79e6 Fix path 2022-03-07 15:34:32 -05:00
Matthew Brown
34d6ef3b90 Use direct path 2022-03-07 15:33:16 -05:00
Matthew Brown
2034fc3f8b Hard-load stringable interface 2022-03-07 15:31:10 -05:00
Matthew Brown
d54011467e Pin twice 2022-03-07 15:23:07 -05:00
Matthew Brown
8785b16572 Revert change to humbug/box version 2022-03-07 15:18:52 -05:00
Matthew Brown
48d37eaade Pin PHP 8.0 polyfill version 2022-03-07 15:12:09 -05:00
Matthew Brown
da47f198ad Remove reference 2022-03-07 14:59:11 -05:00
Matthew Brown
d17435252a Remove unused class 2022-03-07 14:57:13 -05:00