1
0
mirror of https://github.com/danog/psalm.git synced 2024-12-12 09:19:40 +01:00
Commit Graph

162 Commits

Author SHA1 Message Date
Matt Brown
414057e281 Fix #938 - allow forbiddenFunctions to be specified in the config 2018-09-18 16:42:51 -04:00
Matt Brown
add7c14b44 Fix #965 - invalidate cache when changing plugins 2018-09-04 15:28:03 -04:00
Matt Brown
17ea48eda4 Add ability to pretend that a file has declare(strict_types=1) 2018-08-29 15:10:56 -04:00
Matt Brown
2599d8bd62 Allow some folders to be excluded from type stats collection 2018-08-24 17:46:13 -04:00
Matthew Brown
d41a9a8dcc Fix #806 - allow specification of functions and static methods that exit 2018-07-12 23:26:08 -04:00
Tyson Andre
a3b1bebb5b Fix misuse of preg_quote (#869)
1. Variable ids can contain slashes or dots, e.g. for `${'my/var'} = 2`
   or psalm's local representation of properties or array indexes
   (I forget which)
2. preg_quote's escape character should **always** be the same as the
   pattern starting character.
   Using DIRECTORY_SEPARATOR will fail to escape '/' on windows.
2018-07-06 19:16:31 -04:00
Matt Brown
4a4d091c02 Fix #858 - scan files before autoloading them 2018-07-03 11:17:52 -04:00
Matthew Brown
16e270f0ee Improve loading of stub file and autoload file information
Ref #849
2018-06-30 15:29:37 -04:00
Matt Brown
89cc63846f Improve handling of autoloaded files
Fixes #848
2018-06-29 15:28:45 -04:00
Matthew Brown
e1d922e9df Add support for ignoredExceptions 2018-06-22 01:26:10 -04:00
Matthew Brown
e3ae1bf26f Fix #15 - check for uncaught throws if config flag is set 2018-06-22 01:13:49 -04:00
Matthew Brown
3670f066bb Improve dead code detection 2018-06-16 20:01:41 -04:00
Matt Brown
f030f4f40d Allow docblock types to be merged with param default ones 2018-06-07 12:23:21 -04:00
Matthew Brown
53bfafa02a Make sure that ignoreFiles files never appear in errors 2018-06-04 00:15:28 -04:00
Matthew Brown
55fdef250e Add config to allow hoisting constants to the top of a file 2018-06-01 09:07:22 -04:00
Matthew Brown
ee9fef050a Add support for function checking plugins 2018-05-31 22:00:11 -04:00
Matt Brown
68dbe509a8 Fix #731 - report issues in files required by the source 2018-05-30 12:23:53 -04:00
Matthew Brown
c217849737 Improve handling of projects that use include/require heavily 2018-05-22 23:39:01 -04:00
Matthew Brown
b0733254bb
Use individual type objects for each string (#757)
* Experiment with individual types for each string

* Fix bunch of errors

* Fix a few more issues

* Fix a whole bunch of bugs

* Fix most remaining bugs

* Fix isset warnings

* Fix psalm errors in psalm

* Limit big string size

* Fix falsiness of ints

* Fix issue with type widening, allowing value set in nested if to be altered

* Don’t complain if type is mixed

* Add skipped-for-now test

* Add specific test to address issue
2018-05-18 11:02:50 -04:00
Matthew Brown
a33d52d935 Add support for referencedProperty error restrictions 2018-05-11 00:07:41 -04:00
Matthew Brown
da6209276f Allow ability to memoize empty method calls based on config 2018-04-28 13:05:43 -04:00
Matthew Brown
1c7568e612 Fix #642 - allow @method to override existing methods
behind usePhpDocMethodsWithoutMagicCall="true"
2018-04-21 23:08:08 -04:00
Matthew Brown
8b50cdf315 Fix #632 - add support for @method annotations when method can’t be found 2018-04-21 22:44:54 -04:00
Matthew Brown
da69e60cf3 Don’t error on existing Psalm configs cc @ostrolucky 2018-04-21 19:05:26 -04:00
Matt Brown
a25a989c12 Prepare v2 dev release 2018-04-19 17:29:07 -04:00
Radosław Kowalewski
eab7f7b68b Suppress MixedArgument 2018-04-14 10:45:05 -04:00
Radosław Kowalewski
88bf8e284c Configuration fallback to psalm.xml.dist file
Closes vimeo/psalm#644
2018-04-14 10:45:05 -04:00
Matt Brown
21b74ae725 Turn useAssertForType on by default (was off) 2018-04-13 17:35:56 -04:00
Matt Brown
8fdd827e0d Fix scope leaking from autoloader 2018-04-13 10:32:08 -04:00
Matthew Brown
75e59f29ea Check as many autoloaded files as possible
and ignore reflected function docblocks - fixes #629
2018-03-30 20:03:56 -04:00
Matthew Brown
5384f193d1 Allow class and method issues to be suppressed by their identifiers
Ref #603
2018-03-20 22:36:03 -04:00
Bruce Weirdan
a1f481d8a2 commented out code cleanup 2018-03-08 19:14:06 -05:00
Bruce Weirdan
12488ea8ed dropped commented out code, added file_exists() checks for stubs 2018-03-08 19:14:06 -05:00
Bruce Weirdan
32884774e4 build psalm.phar using humbug/box 2018-03-08 19:14:06 -05:00
Matt Brown
d185253396 Don’t throw exception if classloader hasn’t been set 2018-03-06 17:30:54 -05:00
Matt Brown
357ad1aa82 Add config flags to allow stricter class invocation checks 2018-03-06 11:20:59 -05:00
Matthew Brown
9d48585b0e Fix #552 - fix path that stubs are loaded from 2018-03-03 19:05:15 -05:00
Matthew Brown
6458aa2e91 Remove unused methods 2018-03-03 15:29:13 -05:00
Matthew Brown
b90a58533b Fix tests and return types 2018-03-03 15:25:35 -05:00
Matthew Brown
ade9e03c85 Use composer autoloader for class resolution where possible 2018-03-03 15:19:05 -05:00
Matthew Brown
9fd009a61d Add more debug output for composer classmaps 2018-03-03 12:15:22 -05:00
Matt Brown
5471b89391 Make array coercion an error 2018-02-21 18:59:31 -05:00
Matt Brown
a81c73301b Warn early if the file being analysed has not been properly scanned 2018-02-21 13:54:11 -05:00
Matthew Brown
724e72af58 Don’t get statements from cache if file hasn’t changed 2018-02-19 11:53:30 -05:00
Matthew Brown
634375ae94 Make igbinary the default serializer
Fix #484 and fix #527
2018-02-19 11:14:07 -05:00
Tyson Andre
aea3779c96 Fix unused imports in psalm, wrong param order doc comments (#523)
(Some of the imports appear as strings elsewhere in the same file)
2018-02-18 17:55:11 -05:00
Matthew Brown
affcaebc3d Use classes, not full method ids, for plugin execution 2018-02-11 22:49:19 -05:00
Matthew Brown
e862e4ddb1 Make all plugin methods static
cc @TysonAndre
2018-02-11 20:56:34 -05:00
Matt Brown
fc58655963 Make logic more Psalm-compatible 2018-02-06 13:52:59 -05:00
Matthew Brown
8e0998e081 Break apart the Codebase class 2018-02-03 18:56:54 -05:00