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

10877 Commits

Author SHA1 Message Date
Bruce Weirdan
220d656706
Added backward compatibility check 2022-02-04 04:15:32 +02:00
orklah
c5722dd5e8
Merge pull request #7574 from AndrolGenhald/add-extensions-to-version-message
Fix extension capitalization issue, add extensions to version message.
2022-02-03 21:23:14 +01:00
AndrolGenhald
588d9e08bc Fix extension capitalization issue, add extensions to version message. 2022-02-03 11:34:50 -06:00
orklah
cfce264bba
Merge pull request #7565 from AndrolGenhald/fix-docs-bullet-indentation
Fix bullet indentation in documentation
2022-02-02 22:27:05 +01:00
AndrolGenhald
94eda1a9f9 Fix bullet indentation in documentation. 2022-02-02 14:48:24 -06:00
orklah
0fe14498fc
Merge pull request #7564 from AndrolGenhald/fix-globals-documentation
Fix documentation for <globals> config.
2022-02-02 21:43:32 +01:00
AndrolGenhald
9429010fda Fix documentation for <globals> config. 2022-02-02 14:38:01 -06:00
Matthew Brown
8098755ce5 Remove comma 2022-02-02 11:29:31 -05:00
Matthew Brown
b382d7db3c Remove some unnecessary code around taint analysis 2022-02-02 11:25:03 -05:00
Matthew Brown
2b81990259 Simplify var naming 2022-02-02 11:25:02 -05:00
orklah
2e01e9b7cd
Merge pull request #7396 from Patrick-Remy/feat/key-of-value-of-improvements
feat: make key-of/value-of usable with non-const arrays
2022-01-31 21:39:01 +01:00
Patrick Remy
f480eb2c94
docs: add key-of/value-of BC to UPGRADING 2022-01-31 21:30:04 +01:00
Patrick Remy
51d4bf556a
fix: replace template args in key-of/value-of
Extend TTemplateKeyOf from Atomic instead of Scalar, to ensure it is
only compared in AtomicTypeComparator to reduce duplicate code.
2022-01-31 20:53:36 +01:00
Matthew Brown
fcfd4d30f3 Simplify passing in template result for calls 2022-01-31 09:36:40 -05:00
Bruce Weirdan
958e3cc12b
Merge pull request #7492 from zoonru/all_template_parameters 2022-01-31 12:25:51 +02:00
6f51b4a432
Fix tests 2022-01-31 10:28:47 +01:00
d0c9272227
Update baseline 2022-01-31 10:09:05 +01:00
54b3f24b30
Update 2022-01-31 10:06:32 +01:00
52872c05a8
Fixes 2022-01-31 10:06:32 +01:00
ada778e8df
Remove unused field 2022-01-31 10:06:32 +01:00
8d0c1c62e8
Ensure all template parameters are specified in classes, interfaces, traits 2022-01-31 10:06:31 +01:00
Bruce Weirdan
997592de64
Merge pull request #7530 from ohader/issue-7528 2022-01-31 10:36:47 +02:00
Bruce Weirdan
b51cb75f76
Merge pull request #7535 from ohader/issue-7534 2022-01-31 10:34:57 +02:00
Oliver Hader
c4c7138329
Update src/Psalm/Plugin/EventHandler/Event/BeforeStatementAnalysisEvent.php
Co-authored-by: Bruce Weirdan <weirdan@gmail.com>
2022-01-31 07:53:44 +01:00
Oliver Hader
ffafccc2ca
Update src/Psalm/Plugin/EventHandler/BeforeAddIssueInterface.php
Co-authored-by: Bruce Weirdan <weirdan@gmail.com>
2022-01-31 07:52:33 +01:00
Oliver Hader
995ecd0964
Update src/Psalm/Plugin/EventHandler/Event/BeforeAddIssueEvent.php
Co-authored-by: Bruce Weirdan <weirdan@gmail.com>
2022-01-31 07:52:24 +01:00
Bruce Weirdan
e3050b17d6
Merge pull request #7526 from ohader/event-naming 2022-01-31 00:44:37 +02:00
Oliver Hader
6fd31cb5fa
[TASK] Remove deprecated AfterFunctionLikeAnalysisEvent::getClasslikeStorage 2022-01-31 00:34:03 +02:00
Bruce Weirdan
421ae3b254
Merge pull request #7538 from weirdan/fix-exceptioncodetest-provider-shape 2022-01-31 00:32:47 +02:00
Bruce Weirdan
0cbcd0fcf9
Fixed ExceptionCodeTest provider to emit array keys 2022-01-31 00:26:23 +02:00
Bruce Weirdan
a2977a5ca9
Merge branch '4.x' into upstream-master 2022-01-31 00:16:27 +02:00
Oliver Hader
ff07a8d662
[TASK] Use final event class declarations 2022-01-30 19:29:12 +01:00
Oliver Hader
f5986950a2
[FEATURE] Introduce BeforeStatementAnalysisEvent
As counterpart to existing `AfterStatementAnalysisEvent` - invoked in
`\Psalm\Internal\Analyzer\StatementsAnalyzer` - this changed introcued
a corresponding `BeforeStatementAnalysisEvent`.

Resolves: #7534
2022-01-30 19:27:19 +01:00
orklah
31941d15e2
Merge pull request #7533 from orklah/emptyBack
add back empty keyword
2022-01-30 18:56:22 +01:00
orklah
84d9b5e10c add back empty 2022-01-30 18:43:44 +01:00
Oliver Hader
e3602bbfe1
[FEATURE] Allow to intercept adding issue in IssueBuffer
This change introduces new `BeforeAddIssueEvent` which is invoked
from `IssueBuffer::add`, which allows to collect and intercept code
issue in a generic way.

Resolves: #7528
2022-01-30 17:46:08 +01:00
orklah
4729eb004a
Merge pull request #7532 from ohader/event-nameing-4x
[TASK] Add AfterFunctionLikeAnalysisEvent::getFunctionlikeStorage
2022-01-30 17:01:30 +01:00
Oliver Hader
1e072cb904
[TASK] Add AfterFunctionLikeAnalysisEvent::getFunctionlikeStorage
AfterFunctionLikeAnalysisEvent's method `getClasslikeStorage` actually
returned the current `FunctionLikeStorage`. This change streamlines the
naming and adds corresponding `getFunctionlikeStorage` method.

Method `getClasslikeStorage` is deprecated in will be removed
in Psalm v5.0.
2022-01-30 16:55:39 +01:00
orklah
f93bd10c61
Merge pull request #7517 from orklah/fixEmptyArray
Fix empty array
2022-01-30 16:14:24 +01:00
orklah
0592c03cda fix issues resulting from previous commit 2022-01-30 16:05:38 +01:00
orklah
5a3735b90a Change code so it handles what it was designed for 2022-01-30 16:05:22 +01:00
orklah
286176f9c3
Merge pull request #7525 from VincentLanglet/exceptionCode2
Fix for Exception->getCode return type provider
2022-01-30 15:42:26 +01:00
Vincent Langlet
854a3412fe Use function 2022-01-30 15:32:55 +01:00
Vincent Langlet
cd3213201d Fix 2022-01-30 15:30:40 +01:00
Vincent Langlet
584344fda3 Failing test 2022-01-30 15:17:18 +01:00
orklah
64d06c6566
Merge pull request #6789 from ohader/issue-6788
Allow plugins to modify Config::$fileExtensions early
2022-01-30 13:17:12 +01:00
Oliver Hader
3fedb5cce6
Apply code styles 2022-01-30 13:06:02 +01:00
Oliver Hader
62a0ece035
!!! Allow plugins to modify Config::$fileExtensions early
ProjectAnalyzer consumed Config::$fileExtensions early in its
constructor - without having processed plugins' modifications,
registering their custom scanners or analyzer implementations.

This change
* adds new specific interface \Psalm\Plugin\FileExtensionsInterface
  to be used by plugin implementations
* extracts file extension handling from \Psalm\PluginRegistrationSocket
  and interface \Psalm\Plugin\RegistrationInterface to a new dedicated
  \Psalm\PluginFileExtensionsSocket and new interface
  \Psalm\Plugin\FileExtensionsInterface
  !!! this is a breaking change in PluginRegistrationSocket !!!
* adds runtime in-memory cache for Config::$plugins
* calls new method Config::processPluginFileExtensions(), providing
  modifications to file extension only early in ProjectAnalyzer
* adjusts documentation
2022-01-30 13:06:00 +01:00
orklah
1220320e0b
fix some iterator stubs (#6970)
* fix some iterator stubs

* fix iterators

* update stubs

* fix a test

* fixes

* fixes

* fix a test

* fix
2022-01-30 01:18:05 +01:00
Bruce Weirdan
963b41d317
Merge branch '4.x' into upstream-master 2022-01-30 00:32:12 +02:00