Brown
bdac01582d
Fix #1989 - support fully-qualified params in @method annotations
2019-08-08 17:25:56 -04:00
Matthew Brown
b2c0993cdc
Add framework for taint analysis to Psalm
...
Ref #611
2019-08-04 10:37:36 -04:00
Matthew Brown
c356b579fd
Prevent empty @template-extends docblock from being a fatal error
...
Fixes #1963
2019-07-28 16:47:06 -04:00
Jeffrey Yoo
ed61bcafda
Issue 1926 unused variable ( #1967 )
...
* add support for Psalter to remove UnusedVariable
* fix issues found by Psalm
* fix stylistic issues found by phpcs
* added more stylistic changes and suppressed UndefinedClass error for Psalm
* suppress TypeDoesNotContainType error for CheckTrivialExprVisitor
* fix whitespace issue raised by phpcs
* fix bug where partial removal of assignment by ref does not process '&' symbol
* Remove workspace files
* remove 'Array_' and 'ArrayItem' classes from blacklist and add 'New_' class to the blacklist
2019-07-24 16:48:54 -04:00
Tyson Andre
5d5a9c6eac
Remove redundant casts and unused use statements ( #1955 )
...
* Remove redundant casts
(not sure about older versions of php-parser)
* Remove unused use statements
2019-07-18 23:37:36 -04:00
Matthew Brown
3df248eea2
Add concept of purity to functions and methods
2019-07-18 01:31:48 -04:00
Brown
96ba4ad7d3
Fix #1925 - prevent LogicException when scanning files
2019-07-10 18:59:02 -04:00
Matthew Brown
6cbf499f14
Fix #1922 - ignore iterable/array when transforming assertions
2019-07-09 07:38:37 -04:00
Matthew Brown
5f8d4edc73
Remove unused param
2019-07-07 09:39:21 -04:00
Matthew Brown
bceb4efde9
Fix #1911 - allow proper namespaces in union assertions
2019-07-07 09:14:23 -04:00
Matthew Brown
da42be175f
Apply PHPCS fixes
...
Fixes #1880
2019-07-05 16:27:53 -04:00
Matthew Brown
802016757c
Fix #1891 - don’t enter class_alias if the class doesn’t exist
2019-07-04 15:46:24 -04:00
Matthew Brown
efe096c7ab
Fix #1897 - add support for unions in @psalm-assert annotations
2019-07-04 15:05:55 -04:00
Matthew Brown
36e2ea6881
Fix #1822 - update use statements with classes
2019-06-30 11:12:50 -04:00
Matthew Brown
ca53019d6b
Simplify class completion lookup
...
Ref #1822
2019-06-29 21:32:26 -04:00
Tyson Andre
791b30a6d8
Fix redundant casts/conditions in psalm ( #1874 )
...
This includes a check for array_map that was accidentally an assignment
2019-06-29 12:32:44 -04:00
Matthew Brown
fc549a431f
Namespace functions
2019-06-29 00:28:31 -04:00
Matthew Brown
f5459e2854
Remove unused var
2019-06-29 00:25:12 -04:00
Matthew Brown
622ad800cc
Don’t rescan if the problem is unbalanced braces
2019-06-29 00:22:41 -04:00
Matthew Brown
cb28c44228
Fix #1873 - allow spread operators in inferred property types
2019-06-28 22:28:35 -04:00
Brown
6514f2084c
Fix #1860 - be less restrictive about class_exists checks
2019-06-28 10:17:59 -04:00
LeSuisse
f29826b958
Fully qualify constants and function calls ( #1849 )
...
This should give a small performance boost.
Part of #1837 .
The change is enforced via phpcs and can be autofixed
with phpcbf.
2019-06-26 16:52:29 -04:00
Matthew Brown
372a512a86
Don’t convert trait self to trait name
2019-06-26 00:28:43 -04:00
Matthew Brown
c0b86bd40d
Use uppercase template_type_extends keys
2019-06-24 23:43:04 -04:00
Matthew Brown
31c8a2e4d7
Add offsets to type tokenisation
...
Ref #1832
2019-06-22 23:30:40 -04:00
Matthew Brown
2a4072b1be
Resolve docblock self refs as soon as possible
...
Fixes #1827
2019-06-20 23:38:10 -04:00
Matthew Brown
2d5f332ebf
Fix #1781 by improving handling of callmap options
2019-06-15 16:10:48 -04:00
Brown
d1630863ad
Fix #1787 - prevent initialisation when nullable isn’t set
2019-06-14 16:53:40 -04:00
Brown
c21e9917fa
Add config flag to prevent inferring property types from constructor
2019-06-10 14:41:21 -04:00
Brown
aa2fde521a
Fix #1703 - infer properties from class params
2019-06-10 12:00:32 -04:00
Matthew Brown
e1255db32a
Prevent if checking unless we’re in a top-level if
2019-06-10 00:02:36 -04:00
Matthew Brown
158a2150a7
Fix #1752 - don’t enter if/else when class/interfaces/functions don’t exist
2019-06-09 23:50:28 -04:00
Matthew Brown
395057c6df
Fix #1738 - constrain template type when class-string<T> is a param
2019-06-08 11:08:08 -04:00
Brown
b00d51b7db
Allow misplaced required params so Psalm still inspects the code
2019-06-07 09:25:12 -04:00
Brown
f309c755f8
Add ability to move classes
2019-06-05 08:50:24 -04:00
Matthew Brown
13779e760e
Fix #1736 - forbid | in @psalm-assert
2019-06-05 00:46:55 -04:00
Brown
778b95d335
Add support for moving class constants
2019-06-04 11:14:49 -04:00
Brown
9d1b620f55
Fix too-long line
2019-06-03 11:26:25 -04:00
Brown
2f29dcce93
Fix #1728 - remove extra data in template-extends annotation
2019-06-03 10:28:54 -04:00
Matthew Brown
c569f3932c
Use separate method for parsing docblocks
2019-06-01 18:44:59 -04:00
Matthew Brown
62be1cc1b0
Add rest of files
2019-06-01 16:57:33 -04:00
Matthew Brown
736f01c29e
Store more accurate return type location
2019-06-01 13:02:20 -04:00
Matthew Brown
909e02d441
Move var docblocks within function
2019-06-01 12:25:57 -04:00
Matthew Brown
dc5a5bcd9d
Simplify var docblock parsing signature
2019-06-01 11:53:32 -04:00
Matthew Brown
7e4de611bf
Migrate class references in static calls
2019-06-01 10:07:45 -04:00
Matthew Brown
cc89b9254d
Add initial ideas for moving static methods
...
Ref #1595
2019-06-01 00:56:54 -04:00
Matthew Brown
fafe73de0a
Suppress issue where we don’t want to autoload
2019-05-26 16:40:02 -04:00
Matthew Brown
790bc53bfd
Fix #1681 - interpret parent annotation properly
2019-05-25 11:51:09 -04:00
Matthew Brown
13b9e133e4
Fix Psalm errors
2019-05-24 02:15:35 -04:00
Matthew Brown
c80f9d8ecd
Add class-based support for key-of
...
Ref #762
2019-05-24 02:12:58 -04:00