Matt Brown
68dbe509a8
Fix #731 - report issues in files required by the source
2018-05-30 12:23:53 -04:00
Matt Brown
14f3f7a998
Fix #763 - always force rescanning of files if issues were found first time around
2018-05-29 10:13:26 -04:00
Matthew Brown
81ae1ca222
Fix #747 - allow Generator to replace Traversable in templated params
2018-05-28 22:26:43 +01:00
Matthew Brown
d98261507f
Fix #769 - add @psalm-assert and @psalm-assert-if-true annotation support
2018-05-28 20:07:42 +01:00
Matthew Brown
c217849737
Improve handling of projects that use include/require heavily
2018-05-22 23:39:01 -04:00
Matthew Brown
dbc0e6dfcb
Use arrays instead of strings for assertions
2018-05-12 19:38:43 -04:00
Matt Brown
5c0f4a999c
Move a bunch of classes to better places
2018-05-11 18:35:02 -04:00
Matt Brown
ae49558de6
Ignore MissingConstructor a little less
2018-05-03 11:38:27 -04:00
Matthew Brown
2fabdf3353
Fix #314 - add a way to indicate @method list is comprehensive
2018-04-22 00:40:30 -04:00
Matthew Brown
d02b148820
Fix #633 - support @method for magic __call methods
2018-04-21 22:13:10 -04:00
Matt Brown
f5ef864168
Improve checks to prevent breaking existing typehints when running psalter
2018-03-23 16:34:45 -04:00
Matt Brown
ef35cfc6fe
Fix #566 - check for abstract methods inheriting from non-abstract ones
2018-03-13 12:52:00 -04:00
Matthew Brown
a0ce8791d3
Detect fatal issues where property access is overridden
...
Fixes #547
2018-03-04 12:24:50 -05:00
Matt Brown
441506ad6f
Fix #216 - scan assert* functions for assertions, then apply to current context
2018-02-23 15:39:33 -05:00
Tyson Andre
7aeacebba4
Fix possible typos in comments and issue messages
2018-02-19 15:35:13 -05:00
Matthew Brown
81fd016120
Fix #193 - allow caching of storages
2018-02-19 00:27:39 -05:00
Matt Brown
279b0bc16e
Fix #511 - check all class references for missing dependencies
2018-02-14 13:34:16 -05:00
Matthew Brown
affcaebc3d
Use classes, not full method ids, for plugin execution
2018-02-11 22:49:19 -05:00
Matthew Brown
8e0998e081
Break apart the Codebase class
2018-02-03 18:56:54 -05:00
Matthew Brown
cf8734a480
Add support for generic classes
2018-01-31 23:27:25 -05:00
Matt Brown
1320b6dd54
Fix #472 - inherit interface method docblocks if defined just once
2018-01-26 11:50:29 -05:00
Matthew Brown
5b45909d6f
Use better method for determining by-reference status of functions
2018-01-13 01:15:00 -05:00
Matthew Brown
5d9ebd06d6
Don’t check classes after extension_loaded call
2018-01-12 23:47:36 -05:00
Matthew Brown
7fa541e39b
Allow reference-returning functions to be passed as arguments of byref functions
2018-01-11 23:18:13 -05:00
Matthew Brown
fb9f20f4b8
Find unused properties with dead code checks
...
Fixes #424
2018-01-10 23:29:18 -05:00
Matthew Brown
752e99ad2e
Reduce PossiblyUnusedParam false positives
2017-12-30 08:47:00 -05:00
Matthew Brown
57592aca41
Fix #409 - PropertyNotSetInConstructor can be suppressed at the property level
2017-12-27 12:27:59 +01:00
Matthew Brown
0ea6540018
Fix #358 , don’t emit PropertyNotSetInConstructor on public final classes/methods
2017-11-29 23:46:56 -05:00
Matthew Brown
a08306973a
Fix #302 - add a way to seal objects with magic properties
2017-11-16 20:47:58 -05:00
Matthew Brown
dd86513fc5
Fix #271 - remove invalid complaint about private overridden method
2017-11-08 21:27:23 -05:00
Matt Brown
1012c23ff5
Fix assertion checks
2017-09-21 16:31:19 -04:00
Matt Brown
3bc497b18e
Fix #217 - bad param count for DateTimeImmutable::getTimezone
2017-09-21 15:36:26 -04:00
Matt Brown
eee8442af6
Fix #199 - allow classes to suppress PropertyNotSetInConstructor warnings
2017-09-13 11:32:13 -04:00
Matthew Brown
8aabcbce35
Introduce UntypedParam warnings when functions are missing param types
2017-09-02 11:18:56 -04:00
Matt Brown
22b6dafe3c
Fix #194 - carry over const definitions
2017-07-28 10:42:30 -04:00
Matthew Brown
e29dd140e3
Refactor scanning and analysis, introducing multithreading ( #191 )
...
* Add failing test
* Add visitor to soup up classlike references
* Move a whole bunch of code into the visitor
* Move some methods back, move onto analysis stage
* Use the getAliases method everywhere
* Fix refs
* Fix more refs
* Fix some tests
* Fix more tests
* Fix include tests
* Shift config class finding to project checker and fix bugs
* Fix a few more tests
* transition test to new syntax
* Remove var_dump
* Delete a bunch of code and fix mutation test
* Remove unnecessary visitation
* Transition to better mocked out file provider, breaking some cached statement loading
* Use different scheme for naming anonymous classes
* Fix anonymous class issues
* Refactor file/statement loading
* Add specific property types
* Fix mapped property assignment
* Improve how we deal with traits
* Fix trait checking
* Pass Psalm checks
* Add multi-process support
* Delay console output until the end
* Remove PHP 7 syntax
* Update file storage with classes
* Fix scanning individual files and add reflection return types
* Always turn XDebug off
* Add quicker method of getting method mutations
* Queue return types for crawling
* Interpret all strings as possible classes once we see a `get_class` call
* Check invalid return types again
* Fix template namespacing issues
* Default to class-insensitive file names for includes
* Don’t overwrite existing issues data
* Add var docblocks for scanning
* Add null check
* Fix loading of external classes in templates
* Only try to populate class when we haven’t yet seen it’s not a class
* Fix trait property accessibility
* Only ever improve docblock param type
* Make param replacement more robust
* Fix static const missing inferred type
* Fix a few more tests
* Register constant definitions
* Fix trait aliasing
* Skip constant type tests for now
* Fix linting issues
* Make sure caching is off for tests
* Remove unnecessary return
* Use emulative parser if on PHP 5.6
* Cache parser for faster first-time parse
* Fix constant resolution when scanning classes
* Remove test that’s beyond a practical scope
* Add back --diff support
* Add --help for --threads
* Remove unused vars
2017-07-25 16:11:02 -04:00
Matthew Brown
c7b0f6685f
Make Psalm a bit faster
2017-07-08 21:19:16 -04:00
Matthew Brown
91bdd65588
Fix #179 - check for abstract method instantiations
2017-06-30 10:24:47 -04:00
Matthew Brown
d8654b8389
Slow down Psalm by checking parent initialisations too
2017-06-30 01:24:45 -04:00
Matthew Brown
688a72c794
Fix #36 - emit issues on deprecated properties
2017-05-25 01:32:34 -04:00
Matthew Brown
4d020bcbdb
Remove unnecessary imports in tests
2017-05-19 00:52:15 -04:00
Matthew Brown
7532e32b9d
Fixed spacing and use statement formatting
2017-05-19 00:48:26 -04:00
Matt Brown
624bba0f5c
Divid pseudo properties into get and set types
2017-05-05 11:20:05 -04:00
Matt Brown
df890fbfb0
Fix #155 - support @property declaration for classes with magic getters & setters
2017-05-04 18:35:05 -04:00
Matthew Brown
60be6f07a0
Delay checks for MissingPropertyType so we can give more useful messages
2017-04-14 23:09:34 -04:00
Matthew Brown
5cd1b6735f
Add even more references in docblocks
2017-03-01 22:27:52 -05:00
Matt Brown
b948198ca9
Also collect use path locations
2017-02-27 18:24:20 -05:00
Matthew Brown
cd5f727d2e
Collect explicit references to classes/methods
2017-02-26 23:09:18 -05:00
Matthew Brown
98b0ed280c
Add support for templating
2017-02-09 20:35:17 -05:00
Matthew Brown
cdcacc395d
Rename DeadCode to UnusedVariable, UnusedMethod and UnusedClass
2017-02-08 00:28:26 -05:00
Matthew Brown
1ece3071f9
Add reference counting for methods and remove dead code
2017-01-29 23:44:05 -05:00
Matthew Brown
e9ba513250
Add classlike reference counts
2017-01-29 22:30:27 -05:00
Matthew Brown
98d4ced24f
Make location of not-set-in-constructor errors more precise
2017-01-26 23:40:22 -07:00
Matthew Brown
6bcc763414
Fix #3 by checking inside __constructor calls for initialisations
2017-01-26 23:23:12 -07:00
Matthew Brown
894b25487f
Fix #71 - prevent instantiation of abstract classes
2017-01-20 00:10:10 -05:00
Matthew Brown
9d1b382820
Fix #48 by recording class definition line number & file path
2017-01-19 23:45:21 -05:00
Matt Brown
77ff99206e
Inherit all parent properties when analyzing method
2017-01-19 13:11:45 -05:00
Matthew Brown
d7096df7a6
Don’t complain about non-user-defined class casing
2017-01-18 00:33:48 -05:00
Matthew Brown
9b06b672ba
Fix #54 - register function constants when function is invoked
2017-01-15 16:43:49 -05:00
Matt Brown
c181f47364
Fix #35 and #40 by improving method signature checks
2017-01-13 12:03:22 -05:00
Matthew Brown
694da2cabd
Simplify a lot of APIs
2017-01-07 14:35:07 -05:00
Matthew Brown
6ee69e547f
Do more to separate out processing steps
2017-01-06 01:07:11 -05:00
Matthew Brown
7609ca02c0
Fix #32 by evaluating all class references in files lazily
2017-01-04 23:42:58 -05:00
Matthew Brown
883ca6a5db
Fix #30 by consolidating properties into single storage array
2017-01-01 19:09:17 -05:00
Matthew Brown
0b3b3f01f3
Fix support for traits returning self
2016-12-31 11:49:04 -05:00
Matthew Brown
c65a0bf181
Move function static arrays into FileStorage
2016-12-30 18:08:07 -05:00
Matthew Brown
b529fa4877
Move static method arrays into MethodStorage classes
2016-12-30 15:53:35 -05:00
Matthew Brown
92fe58b97c
Shift storage from static arrays to dedicated ClassLikeStorage objects
2016-12-30 12:41:14 -05:00