Commit Graph

27 Commits

Author SHA1 Message Date
Denis Zharkov
1f9d56439a Fix KNPE caused by optimizations in control-flow analysis
The problem is that when performing full analysis we do it in
a backward order while result for trivial vals is filled
in a forward one.

It turns out that reversedInstuctions might return a superset of
forward traversed instructions, e.g. in case of dead code in lambda.

At the same time result for trivial vals is constant
for any instruction, thus we can just return its constant value
and use it in the full analysis

 #KT-20895 Fixed
2017-11-14 16:38:28 +03:00
Mikhail Glukhikh
b975b7d26e More accurate CFG for local class constructors (now they are not considered unconditionally executed) #KT-10042 Fixed 2016-03-23 15:04:05 +03:00
Mikhail Glukhikh
99a32b93fb Implemented missed checks for local functions #KT-10449 Fixed
Relevant code/test fixes
2015-12-23 18:22:32 +03:00
Alexey Tsvetkov
1e2256207c Update test data 2015-10-19 20:45:02 +03:00
Mikhail Glukhikh
64543e3f52 Implicit Nothing return type is now deprecated 2015-10-12 13:30:16 +03:00
Yan Zhulanow
e6c0d4692a Fix operator warning on 'Constr()()' 2015-10-08 18:31:04 +03:00
Yan Zhulanow
6db9344659 Fix compiler tests 2015-09-25 19:20:20 +03:00
Denis Zharkov
4850fd10f0 Regenerate test data containing rendered descriptors
Introduced '@' after each annotation
2015-09-18 10:14:39 +03:00
Michael Nedzelsky
bc5c9065d2 fix tests in org.jetbrains.kotlin.checkers 2015-09-08 02:04:32 +03:00
Valentin Kipyatkov
aefe0dd192 Changed highlighting range and attributes of useless elvis operator 2015-06-02 14:35:19 +03:00
Denis Zharkov
44a55e5bf6 Adjust testData to new labels syntax 2015-04-29 14:03:11 +03:00
Stanislav Erokhin
43e24f6b0d Fixed test data for new lambda syntax 2015-03-18 16:06:44 +03:00
Andrey Breslav
0eee83b6ec Lazy logs removed 2014-11-21 18:59:45 +03:00
Svetlana Isakova
2a83053355 Updated lazy log tests 2014-11-21 14:02:45 +03:00
Stanislav Erokhin
b7c473f59e Update lazy.log files 2014-11-17 17:45:01 +03:00
Alexander Udalov
4f0d83a7fe Update lazy logs after field rename 2014-11-11 18:35:39 +03:00
Andrey Breslav
4892369cf4 Diagnostic tests are logging their lazy activity 2014-11-10 17:24:04 +02:00
Alexander Udalov
3a8ad45dec Append newline to EOF for .txt test data files
Reverts and fixes 102f0d3
2014-10-21 03:18:27 +04:00
Nikolay Krasko
e796f88b38 Regenerate test data with constructed descriptors for diagnostics tests 2014-09-18 17:58:23 +04:00
Alexey Sedunov
9fee8600cb Pseudocode: Do not generate implicit return instruction inside of
Unit-typed lambdas
 #KT-5549 Fixed
2014-08-05 18:14:40 +04:00
Alexey Sedunov
9cbcabffa4 Control-Flow Analysis: Reuse pseudo-value information for unused expression analysis 2014-07-28 13:07:37 +04:00
Alexey Sedunov
1c75a5f642 Pseudocode: Generate instructions for superclass constructor calls. Consume value of delegate expression in the by-clause 2014-07-11 19:13:21 +04:00
Svetlana Isakova
0673dc51d6 Test for KT-3162 More precise try-finally error marking
#KT-3162 Obsolete
2014-06-24 16:14:07 +04:00
Svetlana Isakova
8680ff4e88 Do not mark comment next to reachable child as unreachable 2014-06-24 16:14:06 +04:00
Svetlana Isakova
9d4aad3bbc Extracted 'generateBooleanOperation'
Generate magic instruction for '&&, ||' in condition as well
2014-06-21 12:26:34 +04:00
Svetlana Isakova
4279da12f5 KT-5200 Mark unreachable code in lambdas
#KT-5200 Fixed
2014-06-21 12:26:33 +04:00
Svetlana Isakova
79cec6411d Mark only unreachable parts of element if it has reachable parts
like for 'return todo()' mark only 'return'
2014-06-21 12:26:33 +04:00