1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-27 04:45:20 +01:00
Commit Graph

4634 Commits

Author SHA1 Message Date
Bruce Weirdan
094a0651d7
Increase composer timeout
This should prevent random failures we've been observing lately.
2022-01-02 07:06:16 +02:00
Bruce Weirdan
376d2a389e
Merge pull request #7259 from klimick/infer-this-context-for-psalm-if-this-is 2022-01-02 05:31:24 +02:00
orklah
2a6f12296e
Merge pull request #7260 from orklah/6691
forbid calling impure callable in immutable context
2022-01-01 12:08:07 +01:00
orklah
8e5c9f02bb fix test 2022-01-01 11:21:43 +01:00
orklah
8049438408 forbid calling impure callable in immutable context 2022-01-01 11:13:45 +01:00
adrew
29af83bf61 Add tests for psalm-if-this-is variables and template inference 2022-01-01 13:03:17 +03:00
adrew
878dfa2250 Variable types inference in method context when method marked with psalm-if-this-is 2022-01-01 13:03:17 +03:00
orklah
51ba96c09d
Merge pull request #7253 from orklah/5874
allow calling mutation_free function inside a mutation_free context
2021-12-31 00:24:29 +01:00
orklah
6c6eac9f2f fix test 2021-12-30 22:39:30 +01:00
orklah
392402cf6d allow calling mutation_free function inside a mutation_free context 2021-12-30 22:29:36 +01:00
adrew
4a903c71a1 Checking psalm-if-this-is before applying psalm-this-out 2021-12-30 21:48:25 +03:00
Bruce Weirdan
03b7e94748
Merge pull request #7232 from trowski/issue-7196 2021-12-30 10:03:17 +02:00
orklah
f047d5bc53 allow suppressing unevaluatedCode 2021-12-29 00:44:48 +01:00
orklah
3828db52b9
Merge pull request #7229 from orklah/cleanup5
remove always true/false conditions
2021-12-27 22:08:06 +01:00
Aaron Piotrowski
e23a915bb1
Fix first-class callables when used with magic method, built-in, or undefined methods
Closes #7196.
2021-12-27 14:29:33 -06:00
orklah
3ae80983cc fix unused and CS 2021-12-27 20:10:39 +01:00
orklah
9029e1d613 remove always true/false conditions 2021-12-27 19:59:11 +01:00
adrew
87deb19a87 Remove dead code from test 2021-12-27 19:43:06 +03:00
adrew
c0ca383020 Contextual inference for closure param types 2021-12-27 19:35:37 +03:00
sji
a90456ed8b
trim whitespaces in namespaces specified at @psalm-internal 2021-12-27 02:31:11 +02:00
adrew
3d212c642c
Add test for mismatch param type from docblock 2021-12-27 00:45:26 +02:00
adrew
d6d0fc6704
Remove undefined variables 2021-12-27 00:45:25 +02:00
adrew
2e4d75d6bd
Fix closure param type inference in generic context 2021-12-27 00:45:22 +02:00
Bruce Weirdan
fb56d5ce58
Merge pull request #7210 from vstm/improve-cli-utils-argv-handling 2021-12-27 00:35:32 +02:00
orklah
d4fcb7f61c handle literal equality with integer ranges 2021-12-26 21:09:27 +01:00
orklah
fb97980bf9 fix test 2021-12-26 19:27:13 +01:00
orklah
f7b6c4e1b6 escape more special chars in keyed array names that won't be read by the parser 2021-12-26 19:27:13 +01:00
Stefan Vetsch
3893abff72 Use directory separator to make test more portable 2021-12-24 15:55:24 +01:00
Stefan Vetsch
c3752b4a2b Fix psalm issues 2021-12-24 10:59:39 +01:00
Stefan Vetsch
5331091f5e Simplify argv handling, the first element is always the script name 2021-12-24 10:05:52 +01:00
Stefan Vetsch
ecc7400530 Add CliUtilsTest with test cases for old behaviour 2021-12-24 09:54:37 +01:00
orklah
2c9541c1ed flag the context as "inside_conditional" when analyzing leftover cases to prevent emitting unused error 2021-12-23 22:18:27 +01:00
Philip Hofstetter
fdeb1954c2
update docs for enum case deprecation 2021-12-22 06:16:42 +01:00
Philip Hofstetter
e8e968e8c2
recognize Deprecated attribute on enum cases
just like with properties, this recognizes both `Psalm\Deprecated` and
`JetBrains\PhpStorm\Deprecated`
2021-12-22 06:16:42 +01:00
Philip Hofstetter
d45cb64827
allow marking enum cases as @deprecated 2021-12-22 06:16:42 +01:00
orklah
cc618bc916 allow successful destructuring to also be null if the source was nullable 2021-12-20 22:48:27 +01:00
orklah
639b1b94a3 fix stub and fix test 2021-12-20 09:57:06 +01:00
Matthew Brown
2e32a18222 Fix callable negation 2021-12-18 19:42:43 +00:00
S.M. Ataur Rahman
e408abf119 Fixed ignoreTypeStats & useStrictTypes flag value detection for directories in config 2021-12-18 19:59:25 +06:00
orklah
ba6a4d8af5 fix test 2021-12-17 00:16:50 +01:00
orklah
9583d6a7e7 invert stub, add test 2021-12-17 00:12:54 +01:00
Matthew Brown
89a1c5acbc Fix faulty comparison with typed closure 2021-12-16 16:39:08 +00:00
Bruce Weirdan
7e97c5c84e
Merge pull request #7167 from AndrolGenhald/bugfix/7164-conflicting-fake-variable 2021-12-15 20:56:51 +02:00
orklah
16c0496d1c
Merge pull request #7157 from nowaja/master
ISSUE-5962 Fixed wrong line number for @method annotations
2021-12-15 18:37:26 +01:00
orklah
2dfe45a96e
Merge pull request #7152 from orklah/7109
display class-strings in keyed arrays syntax and allow using them for assertions
2021-12-15 18:36:40 +01:00
AndrolGenhald
03ccb9b548 Add test for nested array_map return type. 2021-12-15 11:09:10 -06:00
rarila
97e6511fab Set number of lines before and after namespace. 2021-12-15 04:58:32 +01:00
rarila
7df7c1f070 Format declare(strict_types=1) 2021-12-15 04:42:37 +01:00
orklah
bb687aebba add test 2021-12-15 00:51:59 +01:00
orklah
41fe5534b6
Merge pull request #7159 from AndrolGenhald/bugfix/number-format-optional-arguments
Fix optional arguments in number_format (fixes #7158).
2021-12-15 00:47:35 +01:00