Brown
29c869ed67
Ignore nullable issues on just-coerced types
2019-05-21 12:59:06 -04:00
Brown
034ea725e8
Coerce generic types from empty
2019-05-21 12:12:13 -04:00
Brown
4ecf370900
Coerce mixed values when passed as arguments
2019-05-21 11:51:41 -04:00
Brown
4a434d9a2f
Add separate issue for undefined classes in docblocks
2019-05-15 18:41:26 -04:00
Brown
d7ee952084
Infer closure param type for array_filter/array_map
...
Fixes #664
2019-05-07 16:27:25 -04:00
Matthew Brown
4f8d6a50d8
Don’t emit MissingClosureReturnType when inside call and type can be inferred
2019-05-06 20:47:55 -04:00
Brown
fec1a60e90
Ref #1600 - partial fix inferring param types when none is available
2019-05-06 18:44:10 -04:00
Brown
4f26c8d749
Fix #1597 - ternary else should only know about first conditional expression
2019-05-02 13:43:18 -04:00
Matthew Brown
e08944cae0
Allow diff mode with --find-dead-code
2019-04-27 17:38:24 -04:00
Brown
0e4c8ce482
Split apart TypeCoercion issues, allowing more granular issue filtering
2019-04-25 18:02:19 -04:00
Matthew Brown
3681762a9b
Add detection for callable variable use
2019-04-23 22:31:38 -04:00
Brown
4807ebe04a
Always evaluate static calls when method call cannot
2019-04-18 13:51:34 -04:00
Brown
a529f74473
Add support for tracking callables
2019-04-17 15:45:40 -04:00
Matthew Brown
ea20a2bd04
Fix #1540 - use correct comparison for callable param types
2019-04-12 00:44:10 -04:00
Brown
808522c36f
Add workaround SoapFault::__construct, fixing #1535
2019-04-09 15:06:10 -04:00
Brown
1348d634ed
Improve handling of variadic parameters
2019-04-09 13:58:49 -04:00
bugreportuser
1a4b9ab25f
Allow suppressing exception issues inline
2019-03-31 14:22:19 -04:00
bugreportuser
4fc7e4affc
Give errors for all uncaught exceptions
2019-03-31 14:22:19 -04:00
Brown
1ab6345bac
Fix treatment of PDOStatement::setFetchMode
...
Fixes #1496
2019-03-29 13:26:13 -04:00
Matthew Brown
230680fd1c
Fix #1513 - use correct param types when examining abstract trait methods
2019-03-28 22:47:17 -04:00
Matthew Brown
e9afd3a6f3
Examine arrays in unknown function calls
2019-03-27 22:13:06 -04:00
Brown
783f028f70
Fix #1498 - use template types from parent function
2019-03-25 11:25:43 -04:00
bugreportuser
8b12751007
Keep track of throw code locations
2019-03-24 23:03:37 -04:00
Matthew Brown
ee56419fd6
Improve accuracy and durability of mixed counts
2019-03-23 09:50:47 -04:00
Brown
b9ba24929d
Refactor storage of template names to prevent clashes
2019-03-22 15:59:10 -04:00
Brown
8d06c6a700
Fix #1480 by remembering where a property was set
2019-03-19 19:43:18 -04:00
Brown
6081c742c5
Fix incorrect InvalidArgument for array value scalar mismatch
2019-03-19 16:45:26 -04:00
Brown
880b07783f
Error should be InvalidScalarArgument
2019-03-19 16:12:38 -04:00
Matthew Brown
2f8bfffe95
Fix #1475 but, like, properly this time
2019-03-17 13:50:02 -04:00
Matthew Brown
a0659a02f1
Fix #1418 - support templated union types
2019-03-16 11:15:25 -04:00
Matthew Brown
85f0fa6e7d
Add support for literal templated defaults
2019-03-07 22:32:38 -05:00
Matthew Brown
472cdf6bea
Fix #1379 - allow @param-out to change type
2019-03-03 15:11:09 -05:00
Matthew Brown
efbcf7dc5b
Fix #1417 - store root file path when scanning for manipulations
2019-03-02 15:07:26 -05:00
Matthew Brown
5c76ab35c8
Allow properties to be set regardless of visibility
2019-03-01 17:30:55 -05:00
Matthew Brown
317f790bde
New plugin hooks ( #1405 )
...
* Add a bunch of new hooks
* Add more integrations
* Add some broken tests
* Add more things
* Fix remaining interfaces
* Suppress proper issue
* UndefinedMethod should not stop analysis
* Add handlers for two custom method return types
2019-03-01 08:57:10 -05:00
Matthew Brown
4f770d356e
Fix #1384 - evaluate array fetches even when we don’t know function
2019-02-24 09:58:11 -05:00
Matthew Brown
cdae79b9fe
Fix unnecessary params in Psalm codebase
2019-02-23 11:31:33 -05:00
Matthew Brown
1c8a573b5f
Change TGenericParam to TTemplateParam
2019-02-21 21:40:06 -05:00
Brown
b7a0950aea
Prevent passing casts to byref vars
2019-02-21 13:26:37 -05:00
Brown
1e2c29041f
@param-out should not override @param byref type def
...
when checking for unuitialised vars
2019-02-20 18:53:42 -05:00
Brown
079ac44263
Prevent pass by ref when type type is given
2019-02-20 17:43:12 -05:00
Matthew Brown
6b419452af
Fix #1337 - don’t crash when examining __call methods in initialisation checks
2019-02-18 16:04:27 -05:00
Matthew Brown
40a91eab6e
Fix #1339 - no crash when using self/static/parent in closure
2019-02-17 13:14:59 -05:00
Brown
27c99aed2f
Improve recovery from InvalidScalarArgument issue
2019-02-14 16:55:54 -05:00
Matthew Brown
dfe45e7d26
Fix #1290 - improve handling of more specific template
2019-02-06 15:56:40 -05:00
Matthew Brown
f06ed8bf84
Fix #1273 - don’t change type with unpacked var
2019-02-03 16:36:10 -05:00
Matthew Brown
e97d4f85ee
Break large CallAnalyzer funtions apart
2019-02-03 16:21:37 -05:00
Matthew Brown
194bb31221
Fix #204 - allow missing param types to be added with Psalter
2019-02-02 14:16:49 -05:00
Matthew Brown
3a01afbe0a
Refine inferred type when possible
2019-02-02 12:10:52 -05:00
Matthew Brown
db89b3cc3f
Add initial support for fixing MissingParamType
2019-02-02 11:28:48 -05:00
Brown
9edbae2bdc
Fix possible fatal when builtin function is called in array_filter
2019-01-28 17:54:50 -05:00
Matthew Brown
8bc17e47be
Fix #1227 - allow genric params in @psalm-assert
2019-01-22 23:42:54 -05:00
Matthew Brown
ea137fc20c
Don’t complain about mixed after unpacking arg
2019-01-21 17:42:25 -05:00
Matthew Brown
e0067e53c5
Fix param chosen to be expected
2019-01-21 17:35:55 -05:00
Matthew Brown
1b0c426c52
Improve error message when type cannot be inferred, fixes #1110
2019-01-21 17:29:12 -05:00
Matthew Brown
ed68cb973d
Fix #1109 - add bad usort protection
2019-01-19 18:11:49 -05:00
Matthew Brown
ee2b06ac43
Add initial support for @param-out
2019-01-19 13:32:43 -05:00
Brown
8d61cb4816
Fix #1200 - no fatal error in array_map when not checking functions
2019-01-15 17:53:23 -05:00
Matthew Brown
9ef1ce1535
Make @template-extends more robust
2019-01-12 18:18:23 -05:00
Matthew Brown
a49b5af3e9
Refactor the method call analyzer a little
2019-01-12 09:13:54 -05:00
Brown
cdbc63c99a
Fix #1195 - check assignments in byref
2019-01-11 14:57:21 -05:00
Brown
bf327f4933
Prevent echo removing all types
2019-01-11 14:46:03 -05:00
Brown
4ec8d1a8dd
Fix #1198 - add support for template param extends checks
2019-01-11 10:55:44 -05:00
Brown
b8d822cd26
Prohibit leaking of template params across class boundaries
2019-01-10 12:13:49 -05:00
Matthew Brown
11bfaaa5f7
Prevent crash in constructor checks
2019-01-09 08:35:53 -05:00
Brown
14f456e160
Fix #1176 - always evaluate assignments in unknown function calls
2019-01-07 12:24:44 -05:00
Matthew Brown
b19dd25881
Fix #742 - infer template type from closure
2019-01-06 12:16:09 -05:00
Matthew Brown
f5378bdca8
Improve function call resolution
2019-01-05 14:50:11 -05:00
Matthew Brown
9d8c2792e2
Add array-key type and improve general type handling
...
Fixes #1144
2019-01-05 00:15:53 -05:00
Brown
2b4b55fd33
Add support for @return no-return
...
Fixes #1155
2019-01-02 17:05:39 -05:00
Matthew Brown
947e3bf0f1
Fix crashes when analysing aliased class instances
2018-12-21 11:32:44 -05:00
Brown
ca1a615026
Don’t call reconciliation on empty vars
2018-12-17 15:23:56 -05:00
Matthew Brown
8b5e8402a1
Add support for @param T:class $foo
2018-12-13 00:09:01 -05:00
Matthew Brown
f0969cb3bb
Fix getId calls on callable return types
...
Ref #1119
2018-12-08 14:10:06 -05:00
Matthew Brown
fd0ab47b80
Fix #1118 - detect possible issues with unions of mixed
2018-12-08 13:18:55 -05:00
Matthew Brown
b32000fa05
Fix #689 - add checks for @internal annotations
2018-12-01 18:37:49 -05:00
Matthew Brown
21f29e7385
Fix #1108 - add support for referencedFunction to UndefinedFunction
2018-11-29 23:19:33 -05:00
Brown
04b3fd2bb5
Fall through after more Possibly* issues
2018-11-28 11:45:54 -05:00
Matthew Brown
6ef79a0432
Improve handling of byref vars passed into functions
...
Fixes #1066
2018-11-21 12:38:51 -05:00
Matthew Brown
59b9b5d65b
Move more classes into Internal namespace
2018-11-18 12:41:47 -05:00
Brown
f3599a8b6c
Allow assertSame(null, ...)
2018-11-16 11:50:07 -05:00
Brown
425b6321aa
Add better understanding of when floats and ints can be equal
2018-11-16 11:04:45 -05:00
Brown
08d9940259
Change ^ to = when annotating assertions
2018-11-16 10:13:52 -05:00
Matthew Brown
e8716f636e
Prevent templated assertions on union types with > 1 atomic
2018-11-16 00:56:57 -05:00
Brown
029b6e5ac4
Allow assertions to be made on template params
2018-11-15 18:50:08 -05:00
Brown
d9440c7bb0
Make sure assertions always have a $ in var id
2018-11-14 15:40:56 -05:00
Brown
f8ea3567d3
Include $ in asserted var id
2018-11-14 15:12:55 -05:00
Brown
3ba2510096
Prevent bleeding of assert vars into context
2018-11-14 13:12:31 -05:00
Brown
4904ffe8ea
Complain about redundant conditions on custom asserts
2018-11-14 12:25:17 -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