Matthew Brown
473a174f23
Memoise type tokenisation and move functions to more logical locations
2018-02-04 12:23:32 -05:00
Matthew Brown
7d6dc7252a
Allow methods that extend nullable callmap methods to not return a value
2018-02-04 09:22:24 -05:00
Matthew Brown
645602a38e
Properly namespace @property types
2018-02-03 23:10:22 -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
Matthew Brown
8b740110f4
Remove more ? from docblocks
2018-01-28 17:07:09 -05:00
Matthew Brown
0cf8bb435f
Remove more unused code found by Psalm
2018-01-28 13:46:18 -05:00
Matthew Brown
dd32452d90
Remove more dead code found by Psalm
2018-01-28 12:43:19 -05:00
Matthew Brown
f628187de9
Remove dead code found by improved Psalm checks
2018-01-28 12:01:51 -05:00
Matt Brown
543872f186
Allow @psalm-ignore-falsable-return annotation
...
Downgrades issues around use of current(), reset(), end() etc.
2018-01-24 18:52:58 -05:00
Matthew Brown
bc9761f6c9
Create Codebase out from ProjectChecker
2018-01-21 13:45:33 -05:00
Matthew Brown
e05a7c00cc
Break FileScanner out from FileChecker
2018-01-21 12:44:46 -05:00
Matthew Brown
bd6e4a09bd
Refactor to break up too-large-files
2018-01-14 12:09:40 -05:00
Matthew Brown
95553ffc0e
Fix by ref method location
2018-01-13 01:25:13 -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
d61829adde
Allow the use of property docblocks without all docblocks
2018-01-13 00:32:20 -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
75daea5f04
Fix #382 - improve reserved word checks
2018-01-10 00:07:47 -05:00
Matt Brown
3b5ddb8dc2
Reduce use of __toString and remove profiling
2018-01-09 15:44:31 -05:00
Matt Brown
edde8930af
Speed up Psalm by caching result of Union::getId
2018-01-09 15:05:48 -05:00
Matt Brown
b373d6093a
Be more lenient with nullable docblock types, allow no return statements
2018-01-08 17:17:49 -05:00
Matthew Brown
693c7a81fa
Improve tracking of docblock types
2018-01-07 17:25:23 -05:00
Matthew Brown
6f5a214365
Allow param redefinition, but complain if it differs to parent class
2018-01-05 00:19:35 -05:00
Matthew Brown
81cfe09fae
Improve reporting of classlike locations in docblocks
2018-01-01 20:04:03 -05:00
Matthew Brown
f81642c1eb
Fix location of function param vars
2017-12-29 21:28:21 -05:00
Matthew Brown
57592aca41
Fix #409 - PropertyNotSetInConstructor can be suppressed at the property level
2017-12-27 12:27:59 +01:00
Tyson Andre
e2e86beee7
Fix a possibly undefined variable seen when issue is suppressed ( #391 )
2017-12-15 12:07:34 -05:00
Tyson Andre
136d48f77c
Support @property-read and @property-write as new tags. ( #317 )
...
In combination with `@psalm-seal-properties`, this can be used to
have in-depth checking of magic properties.
2017-12-14 14:22:27 -05:00
Matthew Brown
a8a1489a8f
Fix closure naming convention so it doesn’t confuse method id checks
2017-12-05 01:47:49 -05:00
Matthew Brown
cff7f35d00
Change __toString type conversions to more precise getId checks
2017-12-03 12:44:08 -05: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
5df8935e14
Make sure @property types have from_docblock === true, fixes #351
2017-11-28 23:00:26 -05:00
Matthew Brown
f27bd50abe
Add RedundantCondition issue, replacing FailedTypeResolution ( #344 )
...
* Group changes
* Don’t worry about vars defined before exiting
* Fix issues with vars defined in conditionals
* Add failing test
* Only add failed reconciliation flag if nothing could be salvaged
* Avoid notice when removing clauses
* Improve handling of loops
* Fix evaluation of binary op expressions
* Remove unset vars from outer context after loop
* Ignore RedundantCondition in some more configs
2017-11-28 00:46:41 -05:00
Matt Brown
b8b1169a03
Consolidate intersection type checks in one place
2017-11-27 18:07:38 -05:00
Matt Brown
318e7c2366
Add workaround for interface instanceof issue
2017-11-27 17:39:25 -05:00
Matthew Brown
afcbc113c9
Fix #228 , fix #336 by improving checking of inherited signatures
2017-11-26 16:03:17 -05:00
Matthew Brown
e3b688b06d
Fix #316 - self resolves to proper class
2017-11-21 21:50:39 -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
440db3be89
Fix #313 - correctly analyse closure self return types
2017-11-16 20:06:00 -05:00
Matthew Brown
3ade4b9559
Fix #293 , be case invariant to self & static
2017-11-14 21:56:29 -05:00
Matthew Brown
b2ae9a2892
Fix #291 , #292 and #297 by improving docblock parsing
2017-11-14 21:43:31 -05:00
Matthew Brown
b79ad3c64b
Fix #282 - detect legacy functions with variadic behaviour
2017-11-11 01:06:39 -05:00
Tyson Andre
e2dd3db70f
Fix phpdoc in psalm's codebase referring to missing params. ( #273 )
...
Also, don't use `@return self` in __construct, it returns void.
2017-11-08 23:32:22 -05:00
Matthew Brown
765d82548d
Remove more dead code
2017-11-08 23:27:51 -05:00
Tyson Andre
b3505cfbef
Get rid of unused variables in psalm's codebase ( #272 )
...
* Remove unused variables
* Fix more unused variables
* Fix remaining detected undefined variables
Other 20 detected undefined variable warnings were false positives.
2017-11-08 23:14:27 -05:00
Matthew Brown
dd86513fc5
Fix #271 - remove invalid complaint about private overridden method
2017-11-08 21:27:23 -05:00
Matt Brown
e0371aed62
Introduce file manipulation concept to plugins
2017-11-07 14:46:53 -05:00
Matthew Brown
032cd3b897
Fix #254 - catch parse exception when improving function types
2017-10-22 01:04:35 -04:00
Matt Brown
dbcec1be38
Fix #249 - get out of nested class
2017-10-19 14:40:38 -04:00