Mikhail Glukhikh
8884cbe415
Introduce FIR_IDENTICAL for FIR vs old frontend tests #KT-36879 Fixed
2020-03-05 09:39:40 +03:00
Ilya Chernikov
6356807997
Reapply "Only create descriptors for candidates with lambda args"
...
#KT-36247 fixed
A lot of testdata changed because significanly less (error) descriptors
are created for unresolved types, so diagnostics became different.
2020-02-14 11:41:30 +01:00
Pavel Kirpichenkov
15d744c3da
[NI] Continue resolution after unstable smart cast on receiver
...
The old inference cosideres candidates with unstable smartcast on
receiver unsuccessful, therefore another one may be selected.
KT-36264
2020-02-13 18:02:38 +03:00
Pavel Kirpichenkov
e40ba73950
[NI] Add resolution applicability for resolved candidates with error
...
New resolution applicability is needed in cases when error is found,
but candidate still should be selected. Currently there are two cases,
when this behaviour is required:
- unstable smartcast (choose candidate with non-nullable parameter)
- unknown lambda parameter type (against non-functional expected type)
KT-36264
2020-02-13 18:02:37 +03:00
Dmitriy Novozhilov
6735cc8937
[FIR] Implement new bound smartcast algorithm
...
#KT-36055 Fixed
2020-02-12 10:17:45 +03:00
simon.ogorodnik
645602b675
[FIR] Fix data-flow after while loops
2020-02-03 16:45:20 +03:00
Dmitriy Novozhilov
9684ff7071
[FIR] Don't create smartcasts to error types
2020-01-22 14:49:23 +03:00
Dmitriy Novozhilov
384a094193
[FIR] Unbound aliased variables in DFA more carefully
2020-01-22 14:49:23 +03:00
Dmitriy Novozhilov
d7c85406fb
[FIR-TEST] Mute some failing tests according to changes in DFA
2020-01-22 14:49:22 +03:00
Dmitriy Novozhilov
5f639dd2ae
[FIR-TEST] Update testdata of old frontend tests
2020-01-22 14:49:22 +03:00
Mikhail Zarechenskiy
ae1630f376
[NI] Don't discriminate Nothing-type from resulting ones
...
^KT-32106 Fixed
2019-12-25 14:59:04 +03:00
Dmitriy Novozhilov
2536fa0cd5
[FIR-TEST] Add new testdata generated after changes in previous commit
2019-12-12 16:11:46 +03:00
Dmitriy Novozhilov
b4c8c79931
[NI] Add check for non-null argument type in arguments check
...
#KT-31461 Fixed
2019-05-23 12:22:42 +03:00
Mikhail Zarechenskiy
bcc8802014
[NI] Avoid constraints from expected type for effectively empty system
...
Expression will be checked against expected type later.
Theoretically, this is not very good, but it aligns with the old
inference, plus it helps avoiding multiple type mismatch diagnostics.
2019-04-17 12:55:12 +03:00
Dmitry Savvinov
15a595749b
[NI] Weird testdata change after fixes in ErrorTypes
...
The issue here is that OI infers correct types for (k, v) destructing
declaration, while NI infers errors for them. That happens because NI
resolves iterator() on nullable 'm', but rightfully reports it as
unsuccessful, while OI somehow manages to resolve it to success (and
thus getting nice expected type, allowing destructing declaration to be
resolved in a proper types).
2017-12-07 12:49:56 +03:00
Dmitry Savvinov
ea72c76a37
[NI] Testdata changes after fixes in error types
2017-12-07 12:49:56 +03:00
Dmitry Savvinov
816d89e393
[NI] Improved testdata after changes in applicabilities
...
This commits introduces testdata changes, where NI behaviour strictly
improved, after several previous fixes.
For some tests, just WITH_NEW_INFERENCE directive was added. It
indicates, that some of previous commits first introduced error in that
test, and then some other commit fixed it (netting no overall testdata
change). It is preferrably to keep those annotations until we will
migrate to NI completely, to prevent unexpected regressions.
2017-12-07 12:49:56 +03:00
Mikhail Zarechenskiy
8757298994
Add diagnostics to test data from NI
2017-11-29 02:54:26 +03:00
Mikhail Zarechenskiy
a71238bf94
Place !WITH_NEW_INFERENCE directive to diagnostics test data
2017-11-29 02:53:49 +03:00
baratynskiy
01883a41cb
javac-wrapper: refactoring, fixes and tests
2017-08-29 18:01:36 +03:00
Mikhail Glukhikh
a12877e51c
Add feature support for "smart casts on variables in closures"
...
So #KT-14486 Fixed
2017-08-16 12:34:04 +03:00
Mikhail Glukhikh
a086863561
Preliminary: support smart casts on variables in closures
...
No feature support yet
So #KT-14486 In Progress
2017-08-16 12:33:52 +03:00
Denis Zharkov
bc564af2fc
Regenerate mockJDK using openJDK 7
2017-06-24 17:26:01 +03:00
Mikhail Zarechenskiy
7a9e1b2b1d
Improve diagnostic on overload resolution ambiguity
...
Report type mismatch on argument when a nullable argument is passed to non-null parameter.
Note that this affects only functions with simple types without generics
#KT-2007 Fixed
#KT-9282 Fixed
2017-06-22 13:41:31 +03:00
Mikhail Glukhikh
630af6a9c6
Correct 1.1-specific test to fix 1.2-M1 build
2017-06-09 13:10:37 +03:00
Mikhail Glukhikh
adbece82ef
Clear DF info for variables assigned in 'try' #KT-17929 Fixed
2017-05-26 15:39:27 +03:00
Mikhail Glukhikh
0fd70df681
Add tests for KT-17929
2017-05-26 15:39:25 +03:00
Mikhail Glukhikh
b7fb45f36e
DFA: only stable values or qualified with stable receiver can be bound in x = y #KT-15792 Fixed
2017-01-23 13:38:24 +03:00
Valentin Kipyatkov
41ee06ec96
Use parameter names in DescriptorRenderer
2016-10-11 23:38:49 +03:00
Alexander Udalov
090d157f86
Update test data for data classes
2016-09-15 16:45:48 +03:00
Mikhail Glukhikh
6a9d058db4
UNUSED_VALUE is now reported on expression only if this expression is unused in all (e.g. finally) branches #KT-9825 Fixed
...
(cherry picked from commit aac8e94)
2016-08-31 19:28:00 +03:00
Ilya Gorbunov
d943079557
Exception typealiases rendering in test output
2016-08-17 12:40:50 +03:00
Mikhail Glukhikh
4f7d8e34b0
Data flow values: initializers for local variables are now stored as "bound values" with inherited nullability #KT-6840 Fixed
2016-07-27 16:24:50 +03:00
Mikhail Glukhikh
c7af3f7865
Data flow values: more accurate handling of postfix ++ and --
2016-07-27 16:24:27 +03:00
Denis Zharkov
b94baede38
Minor. Fix rendered Throwable member scope
2016-04-25 17:41:08 +03:00
Ilya Gorbunov
5361f6e941
Make Throwable properties message and cause open.
...
#KT-5587 Fixed
2016-02-08 18:10:46 +03:00
Mikhail Glukhikh
5062ce2804
Regression: correct smart cast from Type? to Type!
2016-01-28 17:08:15 +03:00
Mikhail Glukhikh
e9af4d25d0
Handling of try / catch / finally with 'Nothing' in all catch blocks #KT-10735 Fixed
2016-01-22 16:37:22 +03:00
Mikhail Glukhikh
366ab508e1
Data flow analysis: assignment of null makes variable effectively of type 'Nothing?'
2016-01-22 16:37:10 +03:00
Ilya Gorbunov
f4822cd757
Fix testData in compiler: add collections and ranges package to fq-names.
2016-01-22 05:54:38 +03:00
Mikhail Glukhikh
9a6d4c32c5
More accurate handling of "always null" for receivers
2015-11-25 18:26:15 +03:00
Mikhail Glukhikh
89e56093a2
Limit "always null" scope: only for !!, is and dot; senseless comparison rolled back; "smart constant" information for nulls #KT-10029 Fixed
2015-11-25 18:26:08 +03:00
Mikhail Glukhikh
2d9fbf5696
Always null detection
2015-11-09 16:36:34 +03:00
Mikhail Glukhikh
41ebfd025e
More precise diagnostics of smart cast impossible #KT-7240 Fixed
2015-11-03 13:38:51 +03:00
Alexey Tsvetkov
1973573a89
Remove @data from test data
2015-10-19 20:45:00 +03:00
Mikhail Glukhikh
4b35e3b135
Preliminary declaration visitor for estimating local variable's predictability for smart casts
...
Predictability estimation algorithm is completely new, but backward compatibility should present.
A large set of tests. Some updated tests.
Smart casts allowed for captured variables if they are not modified in closure #KT-9051 Fixed
Also #KT-8643 Fixed
Also #KT-7976 Fixed
Correct handling of lambda arguments in functions #KT-9143 Fixed
2015-10-16 20:47:47 +03:00
Denis Zharkov
bd37a10677
Transform *Array.size to properties
2015-10-16 18:16:02 +03:00
Denis Zharkov
f0e3fd617d
Adjust testData to CharSequence.length transformation
2015-10-14 20:39:35 +03:00
Yan Zhulanow
275f3f8954
'operator' checks
2015-10-14 01:29:10 +03:00
Denis Zharkov
cfc9d19825
Transform Collection.isEmpty and Map.Entry.key/value to properties
2015-10-10 12:29:14 +03:00