Matt Brown
b717356f95
Simplify more things
2020-11-27 17:48:39 -05:00
Matt Brown
ffabce19c5
Add complex issue error
2020-11-27 17:02:37 -05:00
Matt Brown
6db8132b4c
Simplify call analysers a bit
...
Ref #4714
2020-11-27 16:31:10 -05:00
Matt Brown
bf696bf82e
Add complexity function name echoing
2020-11-27 05:28:55 -05:00
Matt Brown
4c1cf37d52
Improve error message for UnusedVariable
2020-11-13 12:36:17 -05:00
Matt Brown
165e0db157
Fix style
2020-11-10 16:19:24 -05:00
Matt Brown
b731b53d5e
Add debug stuff for code complexity
2020-11-10 12:49:42 -05:00
Matt Brown
3359e7699a
Rename IfAnalyzer
2020-11-06 20:51:14 -05:00
Matt Brown
3bde327f1b
Break up CommentAnalyzer
2020-11-04 23:25:08 -05:00
orklah
ceaaa39ec3
improve phpdoc ( #4352 )
2020-10-17 12:36:44 -04:00
orklah
ffe7874906
Misc improvements ( #4314 )
...
* extract the operation out of the loop when possible
* remove unnecessary interfaces when already inherited in parent
* simplify expressions
* avoid using alias functions
* redundant phpdoc
* unused imports
2020-10-15 13:23:35 -04:00
Matt Brown
724b25b918
Change control_flow_graph to data_flow_graph
2020-10-13 17:28:12 -04:00
Matt Brown
516141a380
Rename ControlFlowGraph to more appropriate DataFlowGraph
2020-10-13 16:49:03 -04:00
Matt Brown
14efde286f
4.x - refactor unused variable detection
...
This turns unused variable detection into an explicit control-flow problem, where before we had a more simplistic mark-and-sweep algorithm
2020-09-30 12:28:13 -04:00
Brown
da65a4327f
Move taint graph functionality into its own object
2020-09-25 00:37:40 -04:00
orklah
37a2f8a33d
unused use statements ( #4228 )
2020-09-22 01:10:46 -04:00
Brown
56cddd16bf
Rename TaintGraph to ControlFlowGraph because it’s about to do more
2020-09-20 23:59:52 -04:00
Brown
70b8c8c0e4
Revert StatementsAnalyzer change
2020-09-20 21:01:59 -04:00
Brown
ef612ea598
Fix tests
2020-09-20 20:58:34 -04:00
Brown
0f6a271858
Improve file-based suppression of taints
2020-09-20 19:37:25 -04:00
Brown
5c23a3d7b3
Localise taint analysis better
2020-09-20 19:26:49 -04:00
Brown
2968b3b065
Add to StatementsAnalyzer taint object instead of Context
2020-09-20 18:42:21 -04:00
orklah
cb7065ae07
replace deprecated methods with their equivalent ( #4217 )
2020-09-20 08:56:49 -04:00
Brown
249903e18a
Fix style issues
2020-09-13 21:45:07 -04:00
Bruce Weirdan
689027c92d
Support multiple issue types in @psalm-suppress
( #4179 )
...
* Accept multiple issue names in `@psalm-suppress`
Fixes vimeo/psalm#1575
* Accept multiple issue types on statement docblocks as well
* Proper highlighting of individual issues in compound suppressions
2020-09-13 16:41:14 -04:00
orklah
da47588f91
replace return;
by return null;
in every non-void method, add return null;
when mising, add return types, remove redundant phpdoc ( #4176 )
2020-09-13 16:39:06 -04:00
Brown
ded9237176
Fix bad error flagging
2020-09-13 16:38:32 -04:00
Brown
9ed09d2679
Fix #4127 - improve error message for unused closure var
2020-09-12 17:03:11 -04:00
orklah
ead107fa9e
More return types ( #4173 )
...
* add native return types
* redundant phpdoc
2020-09-12 11:24:05 -04:00
orklah
8c7423505a
add native param types ( #4137 )
...
* add native param types
* redundant phpdoc
* add more param types and adds "?" to nullable types
* remove redundant phpdoc
* add more param types and remove redundant phpdoc
* add more param types and remove redundant phpdoc
2020-09-06 19:36:47 -04:00
orklah
f66d57f19d
add native return types ( #4116 )
...
* add native return types
* remove redundant phpdoc
2020-09-04 16:26:33 -04:00
orklah
73f6fcde48
Short list syntax ( #4102 )
...
* Short list syntax
* revert unrelated CS
2020-09-02 00:17:41 -04:00
Brown
6919e88423
Add performance logging under a --debug-performance flag
2020-07-30 15:30:19 -04:00
Brown
eddd7b8c11
Fix #1916 - support @var docblock annotations in more places
2020-07-26 13:23:21 -04:00
Brown
279cad3599
Fix #3755 - prevent crash when throw class not found
2020-07-07 00:29:46 -04:00
Brown
c29b3744ec
Change storage of out types
2020-06-24 11:51:31 -04:00
Brown
8f2e28c36b
Improve tainting of specializable classes
2020-06-19 01:22:51 -04:00
Brown
30907f0269
Clean up comment parsing
2020-05-28 22:14:41 -04:00
Brown
0b2da18f1e
Break up StatementsAnalyzer
2020-05-19 12:56:30 -04:00
Brown
8e5b330c5a
Break apart CallAnalyzer
2020-05-18 22:57:00 -04:00
Brown
ace049a068
Beautify BinaryOpAnalyzer
2020-05-18 18:57:09 -04:00
Brown
5ee1487a01
Make ExpressionAnalyzer more beautiful
2020-05-18 15:13:27 -04:00
Brown
8f2f2617d4
Improve refactor
2020-05-10 22:45:01 -04:00
Brown
5f4d162dd5
Break out type expander into separate class
2020-05-10 22:39:18 -04:00
Brown
8f57d0c738
Fix #3204 - normalise function ids where possible
2020-04-20 21:38:35 -04:00
Brown
a3ae2a713b
Fix #3182 - don’t allow unnamespaced string references to functions in same context
2020-04-19 21:21:18 -04:00
Brown
e55fe0a0e8
Fix #3188 - register global variables as by-reference ones
2020-04-19 13:15:04 -04:00
m0003r
28f740fddb
@psalm-trace is now a specific low-level issue, because plain debug print breaks structured output (after #3080 ) ( #3106 )
2020-04-08 21:03:05 -04:00
m0003r
11edb22c72
Implement @psalm-trace annotation, fixes #3079 ( #3080 )
2020-04-06 12:42:22 -04:00
m0003r
c8e7e43bb0
Type::getString already respects maxStringLength config, there is no need to additional checks ( #3069 )
2020-04-05 14:27:02 -04:00