Andrew Nagy
26434c525f
Merge branch '4.x' of https://github.com/vimeo/psalm into feature/upgrade-lsp
2022-03-25 17:01:05 +00:00
orklah
c74981127f
Merge pull request #7801 from gndk/fix-appveyor-disable
...
Fix disabling of appveyor auto build
2022-03-18 21:16:01 +01:00
orklah
b4ae3a9faf
Merge pull request #7798 from ciaranmcnulty/get-trace-stubs
...
Add return shape for Throwable::getTrace
2022-03-18 19:59:26 +01:00
gndk
70166bd743
Fix disabling of appveyor auto build
2022-03-18 12:31:35 +01:00
Ciaran McNulty
ca185d7f28
Update Throwable::getTrace in stubs
2022-03-18 09:14:37 +00:00
Ciaran McNulty
0b39384325
Add return shape for Throwable::getTrace
...
This is based on the documentation for debug-backtrace:
https://php.net/debug_backtrace
Experimentation that shows the `object` field is not populated for exceptions:
https://3v4l.org/iQoni
And validation on psalm.dev:
https://psalm.dev/r/b35a8df2f3
2022-03-18 09:14:23 +00:00
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
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
Jack Worman
88f9e19acd
#7784 PDOStatement::fetchAll() has incorrect type
2022-03-14 14:11:31 -05:00
Jack Worman
0ab947024b
#7784 PDOStatement::fetchAll() has incorrect type
2022-03-14 13:33:29 -05: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
orklah
c1ad5f6be0
Merge pull request #7775 from fluffycondor/improve-int-range-parsing
...
Improve int range parsing
2022-03-12 08:27:23 +01: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
510456c7c4
Improve scoping a bit more
2022-03-07 16:50:20 -05:00
Matthew Brown
2a9ea7ea71
Support Stringable before PhpToken autoloading
2022-03-07 16:08:24 -05:00
orklah
769e316f52
Merge pull request #7760 from mtk3d/fix/array_column_type_inference
...
Fix #7750 : array_column type inference
2022-03-07 19:00:37 +01:00
Mateusz Cholewka
cd1b155f53
test if the type of second argument is not uncertain
2022-03-07 14:10:03 +01:00
Mateusz Cholewka
483d35980a
check is value for sure is null
2022-03-07 14:07:16 +01:00
orklah
19ac15077f
Merge pull request #7759 from franmomu/fix_array_access_offsetset
...
Allow null to ArrayAccess::offsetSet $offset param
2022-03-06 22:35:00 +01:00
Mateusz Cholewka
d53f57b5f7
wrap row in union again
...
From: https://github.com/vimeo/psalm/pull/7760#discussion_r820264671
$result_element_type should be a Union, $row_shape is an Atomic
(a part of a Union). new Union([$row_shape]); should be ok
2022-03-06 21:28:48 +01:00
orklah
a134b257da
Merge pull request #7758 from Ne-Lexa/fix-dateinterfal-false
...
DateInterval::createFromDateString can be false
2022-03-06 19:57:31 +01:00
Ne-Lexa
7a43baa23c
fixed return type in the historical callmap
2022-03-06 20:47:50 +03:00
Mateusz Cholewka
56e65fd5ba
skip creating unnecessary union
2022-03-06 17:07:56 +01:00
Mateusz Cholewka
70abbbee01
refactor array column test
...
add one more test when index key not exist in array
reorganise samples to keep all similar together
2022-03-06 15:45:22 +01:00
Mateusz Cholewka
88d49b9923
provide array column type for null column
2022-03-06 15:44:56 +01:00
Mateusz Cholewka
d48965d929
add failing test
2022-03-06 14:09:07 +01:00
Fran Moreno
ff195e76c9
Allow null to ArrayAccess::offsetSet $offset param
2022-03-06 13:47:32 +01:00
Ne-Lexa
a57bb1f128
fix #7747 : DateInterval::createFromDateString can be false
2022-03-05 22:37:55 +03:00
orklah
d24b32bb05
Merge pull request #7752 from kkmuffme/patch-1
...
update phpredis stubs
2022-03-04 20:47:50 +01:00
Andrew Nagy
e18f9ccecb
Merge branch '4.x' of https://github.com/vimeo/psalm into feature/upgrade-lsp
2022-03-04 18:04:53 +00:00
Andrew Nagy
e509aad263
ability to debounce onchange events for large projects
2022-03-04 18:04:19 +00:00
kkmuffme
8fc41e6907
update phpredis stubs
...
* fixes feedback for setOption of https://github.com/vimeo/psalm/issues/7709
* latest WIP stubs with additional changes from upstream phpredis master and other additions
From https://raw.githubusercontent.com/phpredis/phpredis/77334ecbf2c06ea1ff18ea5e3ecc168cb1897a8b/redis.stub.php via https://github.com/phpredis/phpredis/pull/2015
2022-03-04 12:56:30 +01:00
orklah
e1997c92f2
Merge pull request #7746 from samsonasik/patch-1
...
Register openssl_sign function to impure functions
2022-03-02 20:02:37 +01:00
Abdul Malik Ikhsan
9666b90e41
Register openssl_sign function to impure functions
...
openssl_sign has $signature parameter that by reference that can re-used
2022-03-02 22:59:12 +07:00
orklah
fc2c6ab4d5
Merge pull request #7727 from AndrolGenhald/attribute-analysis-improvements
...
Attribute analysis improvements
2022-02-24 21:34:05 +01:00