1
0
mirror of https://github.com/danog/psalm.git synced 2024-12-11 08:49:52 +01:00
Commit Graph

75 Commits

Author SHA1 Message Date
Brown
fea9faaec5 Allow psalter to be used in multithreaded mode 2019-04-17 13:15:06 -04:00
Matthew Brown
01f005290e Allow file path to be passed into methodExists 2019-04-17 00:17:49 -04:00
Brown
ff14f671b1 Add hopefully-more-portable method for evaluating method/property usage 2019-04-16 16:07:48 -04:00
Matthew Brown
21fd385eb4
Fix brackets 2019-04-12 20:30:28 -04:00
Brown
26e2de93c7 Prepare to enable paralellised use of --find-dead-code
References #1548
2019-04-12 18:28:07 -04:00
Matthew Brown
0da3623372 Prevent internal consumers of classExists from being penalised 2019-03-17 17:11:04 -04:00
Bruce Weirdan
51460e6078 Codebase::classExtends() now rejects unpopulated classes
This is done to prevent false negatives, when class storage hasn't been
populated yet.

Fixes vimeo/psalm#1387
2019-03-17 13:51:00 -04:00
Brown
bd372e93af Add config flags for findUnusedVariables and findUnusedCode 2019-03-05 15:45:09 -05:00
Matthew Brown
92cba71a06 Add extra arg to return type call 2019-03-03 22:57:40 -05:00
Matthew Brown
3ad1abece4 Add generation of json artifacts 2019-02-24 01:33:25 -05:00
Matthew Brown
cdae79b9fe Fix unnecessary params in Psalm codebase 2019-02-23 11:31:33 -05:00
Bruce Weirdan
991fd90a12 Added tests for exposed methods 2019-02-21 08:43:57 -05:00
Matthew Brown
0e5ee1a811 Fix typo 2019-02-21 08:43:57 -05:00
Bruce Weirdan
adc5d24399 Added documentation for several exposed methods
Documented:
- isTypeContainedByType
- canTypeBeContainedByType
- getKeyValueParamsForTraversableObject
2019-02-21 08:43:57 -05:00
Bruce Weirdan
a0e040a462 Expose more internal methods through Codebase
- `bool Codebase::canTypeBeContainedByType(Union $input, Union $container)`
- `array{Union,Union} Codebase::getKeyValueParamsForTraversableObject(Atomic $type)`

For usage, see psalm/phpunit-psalm-plugin#15
2019-02-21 08:43:57 -05:00
Matthew Brown
81a5a24e15 Suppress PossiblyUnusedMethod 2019-02-18 15:56:31 -05:00
Bruce Weirdan
e87f500458 Added Psalm\Codebase::isTypeContainedByType() 2019-02-18 15:56:31 -05:00
Bruce Weirdan
8408effe57 Dropped unused uses 2019-02-17 13:17:45 -05:00
Matthew Brown
17541b415f Fix #1191 - allow Psalm to check against different versions of PHP 2019-02-07 12:25:57 -05:00
Matthew Brown
0574e06a42 Remove 7.0-incompatible type 2019-01-27 18:31:40 -05:00
Matthew Brown
45cf35350c Add non-internal endpoint for parsing types 2019-01-27 17:26:32 -05:00
Brown
51c6621925 Add property lookup 2019-01-22 11:10:37 -05:00
Brown
2d22db4cb7 Clear up use of reloadFiles 2019-01-02 12:10:52 -05:00
Matthew Brown
947e3bf0f1 Fix crashes when analysing aliased class instances 2018-12-21 11:32:44 -05:00
Tyson Andre
6ab59209d6 Fix usage of substr_count($haystack, $needle)
Detected via a check that literals and variables occur in the most
typical order for a global function.
2018-11-21 13:59:22 -05:00
Brown
b5f0159cdf Add backup hover analysis when file isn’t analysed 2018-11-20 16:32:40 -05:00
Brown
ca602f8e17 Fix language server crash after editing trait method names 2018-11-20 15:51:47 -05:00
Brown
0254322bed Migrate Codebase-namespaced and FileManipulation-namespaced classes to internals 2018-11-12 11:20:59 -05:00
Matthew Brown
9709263b8d Make many PropertyAnalyzer properties private 2018-11-12 11:20:59 -05:00
Matthew Brown
4d79b61e93 Change _checker to _analyzer 2018-11-12 11:20:59 -05:00
Matthew Brown
4688b25fd9 Move internal classes to own namespace 2018-11-12 11:20:59 -05:00
Matthew Brown
9f2fe748e8 Improve handling of vars set in always-entered for/foreach/while loops 2018-11-10 16:10:59 -05:00
Brown
f2c013e45f Improve API for setting temporary file contents 2018-11-09 10:42:55 -05:00
Matthew Brown
7d12bfd2d1 Cache errors as well as info issues 2018-11-01 21:52:39 -04:00
Brown
e286089eaa Add onchange events and symbol lookup with disabled completion 2018-10-26 16:17:15 -04:00
Matthew Brown
addaea2c1c Improve performance when parsing large files with few changes 2018-10-26 00:59:14 -04:00
Brown
a41c5c8a39 Fix code quality issues 2018-10-18 09:57:13 -04:00
Brown
b7c438bf97 Fix slowness when invalidating heavily-used files 2018-10-17 18:11:02 -04:00
Brown
54fdda651b Add server mode support with error reporting only 2018-10-17 15:54:31 -04:00
Brown
5a484901cd Improve the way that files are reloaded (server only) 2018-10-16 15:59:11 -04:00
Brown
f9cca5e597 Add support for forking at the scanning step 2018-10-15 09:16:11 -04:00
Brown
55bb896868 Fix bugs Psalm found 2018-10-08 20:04:05 -04:00
Matthew Brown
7e01576653 Fix #1011 - don’t re-analyse constructors if we can help it 2018-10-06 22:58:21 -04:00
Matthew Brown
92e11fd51b Port over cleanup from server branch 2018-10-06 20:11:19 -04:00
Brown
f2cea0325f Slightly improve trait handling 2018-10-03 17:11:08 -04:00
Brown
d0bd10d143 Improve provider architecture, upping test coverage 2018-09-30 11:34:51 -04:00
Brown
05a0bdc93b Remove PHP7 types 2018-09-30 11:34:51 -04:00
Brown
67c90edadf Don’t check methods we’ve already checked 2018-09-30 11:34:51 -04:00
Matthew Brown
16e270f0ee Improve loading of stub file and autoload file information
Ref #849
2018-06-30 15:29:37 -04:00
Matthew Brown
ce1fda46a6 Fix hard-to-resolve constant values 2018-06-27 21:53:25 -04:00