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

10040 Commits

Author SHA1 Message Date
AndrolGenhald
225af970cc Add comments explaining condition for UnusedPsalmSuppress. 2021-12-11 16:14:25 -06:00
AndrolGenhald
684cbfeab9 Add back suppressions for undefined constants on Windows. 2021-12-11 15:37:09 -06:00
AndrolGenhald
bfe7f96b56 Allow suppressing UnusedPsalmSuppress, remove unused suppressions. 2021-12-11 13:23:00 -06:00
orklah
0ba5b0b30a
Merge pull request #7130 from AndrolGenhald/bugfix/fix-class-property-suppression
Class property issue suppression fixes.
2021-12-11 19:12:49 +01:00
AndrolGenhald
51d9652b70 Class property issue suppression fixes.
Fix @psalm-suppress and @psalm-allow-private-mutation being ignored if nothing else is in the docblock.
Fix @psalm-suppress not allowing extra text after the issue name.
Fix PossiblyUnusedProperty and UnusedProperty suppression not working at the property level.
Fix MissingPropertyType suppression not working at the property level.
2021-12-11 11:45:06 -06:00
orklah
858be40d32
Merge pull request #7129 from vimeo/muglug-detect-unused-properties-with-arrays
Detect unused properties that are written to inside arrays
2021-12-11 18:19:26 +01:00
Matthew Brown
4229045c23 Remove array properties that are never read 2021-12-11 11:55:37 -05:00
Matthew Brown
b558748db2 Detect unused properties that are written to inside arrays 2021-12-11 11:42:05 -05:00
Matthew Brown
19ae9e81d2 Remove property that is only written to but never used 2021-12-11 08:51:12 -05:00
orklah
76bb8bc655
Merge pull request #7113 from trowski/first-class-callables
Added support for first-class callables
2021-12-10 22:40:16 +01:00
Bruce Weirdan
4ac0b649da
Merge pull request #7115 from weirdan/array_count_values-for-unknown-arrays 2021-12-10 04:09:53 +02:00
Aaron Piotrowski
3c5e99ed1e
Revert reorder of getting method return type and checking args
Skipping checking args for first-class callables, but fixes handling of other methods.
2021-12-09 19:02:58 -06:00
Bruce Weirdan
3cce69189f
array_count_values return type for uncertain arrays
Fixes vimeo/psalm#7114
2021-12-10 02:45:58 +02:00
orklah
ae765dfba8
Merge pull request #7054 from orklah/6933
fix missing case for displaying varId
2021-12-09 23:54:37 +01:00
Aaron Piotrowski
d5519fc53a
Use $stmt->args directly instead of creating new VariadicPlaceholder 2021-12-09 15:51:48 -06:00
orklah
0716dfcda0 allow Reconciler to retrieve global constant values 2021-12-09 21:27:57 +01:00
Aaron Piotrowski
1f3a37ff02
Add support for first-class callables 2021-12-09 10:54:49 -06:00
orklah
761d5f35b4
Merge pull request #7094 from kamil-tekiela/count_chars-fix
Fix count_chars stubs
2021-12-09 00:14:11 +01:00
Kamil Tekiela
098238ff7f Create test for count_chars 2021-12-08 22:57:32 +00:00
orklah
eefdb95765
Merge pull request #7093 from orklah/7090
don't stop analyzing array, even if we already have a type and we can't create an object like
2021-12-08 22:37:57 +01:00
orklah
604f47d52a
Merge pull request #7106 from orklah/7098
fix reconciliation between positive-int and inferior/superior assertions
2021-12-08 22:29:15 +01:00
Bruce Weirdan
eb2f4dca89
Merge pull request #7103 from AndrolGenhald/feature/3938-decimal-operator-overloads 2021-12-08 23:22:24 +02:00
orklah
3f46377467 don't remove literal ints if the Int type already in Union doesn't cover this specific literal 2021-12-08 22:13:54 +01:00
orklah
edeaada8af simplify reconciliation of literal ints with inferior/superior assertions 2021-12-08 22:13:19 +01:00
orklah
be9037f7b1 fix reconciliation between positive-int and inferior/superior assertions 2021-12-08 21:38:12 +01:00
orklah
b65e37c5f9
Merge pull request #7105 from AndrolGenhald/bugfix/7095
Fix non-empty-literal-string to behave as subtype of non-empty-string (fixes #7095).
2021-12-08 21:02:08 +01:00
AndrolGenhald
466696cda4 Remove decimal extension from Windows CI. 2021-12-08 13:39:13 -06:00
AndrolGenhald
a89e8ec28c Fix non-empty-literal-string to behave as subtype of non-empty-string (fixes #7095). 2021-12-08 13:38:32 -06:00
AndrolGenhald
ba881c80bf Use maybeAdd instead of accepts. 2021-12-08 12:15:32 -06:00
AndrolGenhald
5808d4ea83 Add decimal extension to CI. 2021-12-08 12:10:31 -06:00
AndrolGenhald
b29fc6ad3c Allow operator overloading for Decimal extension (fixes #3938). 2021-12-08 10:59:37 -06:00
orklah
8bd525a55f
Merge pull request #7097 from vimeo/muglug-remove-useless-finally-handling
Remove useless chunk of code in ScopeAnalyzer
2021-12-08 07:08:20 +01:00
Matthew Brown
8daf9c42a9 Remove useless chunk of code in ScopeAnalyzer 2021-12-07 23:42:17 -05:00
Kamil Tekiela
88ce10b1dc Fix count_chars stubs 2021-12-07 21:31:05 +00:00
orklah
0ca856b597
Merge pull request #7064 from weirdan/update-list-of-maintainers
Updated list of current maintainers
2021-12-07 20:57:08 +01:00
orklah
574c8f74dd fix test 2021-12-07 19:48:37 +01:00
orklah
c17af4128e don't stop analyzing array, even if we already have a type and we can't create an object like 2021-12-07 19:38:52 +01:00
Bruce Weirdan
a1b5e489e6
Merge pull request #7089 from marcosh/abs-should-return-positive-int 2021-12-07 13:25:29 +02:00
marcosh
9c4187fd2f fix abs tests 2021-12-07 12:00:52 +01:00
marcosh
07224e7d31 abs should always return a positive integer 2021-12-07 11:52:13 +01:00
Bruce Weirdan
2530b33dbd
Merge pull request #7076 from klimick/fix-generic-assertion 2021-12-07 08:08:48 +02:00
orklah
77e0f09b43
Merge pull request #7084 from orklah/7081
Don't crash when checking purity of __callStatic in a trait
2021-12-06 23:17:20 +01:00
orklah
257d237192 ignore ComplexMethod: didn't see any easy refactoring 2021-12-06 20:13:33 +01:00
orklah
75312d93b1 Don't crash when checking purity of __callStatic in a trait 2021-12-06 19:00:37 +01:00
Bruce Weirdan
4a35a85939
Merge pull request #7077 from ricardoboss/issue-6964-refinement-unitenum-name-property 2021-12-06 01:53:55 +02:00
Ricardo Boss
2ec77fe29c Make name property of enum cases return non-empty-strings (vimeo/psalm#6964) 2021-12-06 00:33:57 +01:00
adrew
dee3fc4358 try to fix generic assertions for list and array 2021-12-06 02:25:40 +03:00
Bruce Weirdan
056497e73d
Merge pull request #7073 from weirdan/strlen-no-negative-returns 2021-12-05 22:04:51 +02:00
Bruce Weirdan
9c324a7d74
Refined strlen() return type to not include negative ints
Fixes vimeo/psalm#7062
2021-12-05 21:35:58 +02:00
rarila
39402c233d
Return type hints (#7065)
Co-authored-by: ralila <>
2021-12-05 19:51:26 +02:00