Commit Graph

209 Commits

Author SHA1 Message Date
simon.ogorodnik a8cd8ad8f8 [FIR] Fix testData after changing anonymous object name 2020-06-19 01:52:02 +03:00
Dmitriy Novozhilov d7ee168dff [FIR] Create error candidate for completion instead of simple error reference 2020-06-15 15:32:25 +03:00
Denis Zharkov 72b09ff323 FIR: Rename FirSuperTypeScope and reuse it for type parameter type
It would allow ConeKotlinType.scope return FirTypeScope
and thus pulling down org.jetbrains.kotlin.fir.scopes.FirScope#processOverriddenFunctions
(See the following commits)
2020-06-11 11:31:31 +03:00
Denis Zharkov 19219c37b6 FIR: Fix test data for KT-13650 related test
Now, the behavior seems to be more correct then in FE 1.0
2020-06-03 10:43:37 +03:00
anastasiia.spaseeva 6c1efbe812 [Spec tests] Update spec testData 2020-05-28 14:23:11 +03:00
Yan Zhulanow ef698a5747 Fix "PSI/index mismatch" in case of @ParameterName on non-functional types (KT-34524) 2020-05-27 02:38:41 +09:00
anastasiia.spaseeva 9d862aaa1d [Spec tests] Remove spec info from fir tests 2020-05-26 17:27:06 +03:00
Victor Petukhov 379c6944a2 NI: extract diagnostics from partially resolved call instead of separately handling it including running all checks
^KT-37630 Fixed
^KT-35494 Fixed
2020-05-22 22:13:53 +03:00
anastasiia.spaseeva c736a1e5b0 [Spec tests] Update testsMap for when-expression section 2020-05-22 02:52:02 +03:00
anastasiia.spaseeva d9160a26e9 [Spec tests] Add property helpers to testMaps 2020-05-22 02:52:02 +03:00
anastasiia.spaseeva 270972ca1c [Spec tests] Make main link nullable for case if implementation tests don't have this one 2020-05-22 02:52:00 +03:00
anastasiia.spaseeva 3a46b5a45a [Spec tests] Add path element at testMaps for main links also 2020-05-22 02:52:00 +03:00
anastasiia.spaseeva d94c212a60 [Spec tests] Add linkType element to testMaps 2020-05-22 02:51:59 +03:00
anastasiia.spaseeva 3a31150df4 [Spec tests] Metadata refactoring: remove duplicated links in testMaps 2020-05-22 02:51:58 +03:00
anastasiia.spaseeva d32aca87d1 [Spec tests] Change metadata structure of implementation and spec tests 2020-05-22 02:51:57 +03:00
Pavel Kirpichenkov 003ba1c8f5 [NI] CST: add preemptive recursion detection
For single super type constructor create star projection argument when types for that argument are equal to the original types.
Captured star projections are replaced with their corresponding supertypes during this check.
Skip check for `in` parameters, for which recursive cst calculation does not happen.
Adjust constant in fallback recursion condition.

^KT-38544 Fixed
2020-05-12 11:13:43 +03:00
Mikhail Glukhikh 52abc2ae1a [FIR] Fix spec test data according to a new diagnostic 2020-05-07 12:10:56 +03:00
Victor Petukhov 260683c20e NI: Improve postponed arguments analysis
Introduce seven stages:
1) Analyze postponed arguments with fixed parameter types
2) Collect parameter types from constraints and lambda parameters' declaration
3) Fix not postponed variables for parameter types of all postponed arguments
4) Create atoms with revised expected types if needed
5) Analyze the first ready postponed argument and rerun stages if it has been analyzed
6) Force fixation remaining type variables: fix if possible or report not enough information
7) Force analysis remaining not analyzed postponed arguments and rerun stages if there are

^KT-37952 Fixed
^KT-32156 Fixed
^KT-37249 Fixed
^KT-37341 Fixed
2020-05-07 11:42:00 +03:00
Pavel Kirpichenkov 86d6470ced Update test data forgotten in 36a57973
KT-38544
2020-04-28 20:26:11 +03:00
Pavel Kirpichenkov 36a57973b5 [NI] CST: remove max depth offset from recursion detection
Recursive type with several recursive anscestors can create a number of identical
common supertype calculations, growing exponentially on every step of recursion.
Previously the number of calculations was limited by D + 3, where D is a type depth.
Since the limit is dynamic, it seems that extra +3 offset can be dropped thus
reducing the number of recursions. The proper solution is to detect such a recursion
and fold recursive type preemtively, but for now this may improve performance in some use cases.

^KT-38544 In progress
2020-04-28 12:53:09 +03:00
Denis Zharkov d66281d11f FIR: Fix test data for spec test after c4b7ac994b 2020-04-23 11:24:49 +03:00
Denis Zharkov 3bb6aa6f28 Mark as FIR_IDENTICAL passing spec tests 2020-04-21 10:16:42 +03:00
Denis Zharkov 82b2825b7a FIR: Ignore flaky spec tests
^KT-38340 Submitted
2020-04-21 10:16:41 +03:00
Denis Zharkov b375e021e5 FIR: Ignore failing spec test
^KT-38397
2020-04-21 10:16:40 +03:00
Denis Zharkov 4c4f220fd0 FIR: Ignore failing spec tests
^KT-38336 Submitted
2020-04-21 10:16:39 +03:00
Denis Zharkov c4d72d6906 FIR: Ignore failing spec test
^KT-38334 Submitted
2020-04-21 10:16:38 +03:00
Denis Zharkov 26f0b044fc FIR: Ignore failing spec test
^KT-38333 Submitted
2020-04-21 10:16:37 +03:00
Denis Zharkov 39d4231894 FIR: Adjust testData for spec tests: discrepancy in DEBUG_INFO_CALL format
In old FE, there are fake overrides rendered, while in FIR there are
real declarations
2020-04-21 10:16:36 +03:00
Denis Zharkov bddea7d163 FIR: Adjust testData for spec tests: local scopes in overload resolution
The behavior of FIR seems to be the correct one

^KT-36475
2020-04-21 10:16:35 +03:00
Denis Zharkov 706ccb2cf9 FIR: Adjust testData for spec tests: invoke on nullable receiver
It's a design problem, see related issue

^KT-30415
2020-04-21 10:16:34 +03:00
Denis Zharkov f0d35a2478 FIR: Adjust testData for spec tests: operator priority
^KT-38351 Submitted
2020-04-21 09:52:52 +03:00
Denis Zharkov 5c7c4b4cb6 FIR: Adjust testData for spec tests: infix priority
^KT-37374 Please, fix the tests
2020-04-21 09:52:52 +03:00
Denis Zharkov 54546eb890 FIR: Adjust testData for spec tests: unsupported DEBUG_INFO_CALL format 2020-04-21 09:52:52 +03:00
Denis Zharkov f8791549f3 FIR: Adjust testData for spec tests: enum "values" priority
^KT-38350 Submitted
2020-04-21 09:52:52 +03:00
Denis Zharkov 2ced716268 FIR: Adjust testData for spec tests: controversial infix calls
^KT-37374 Please, take a look at these tests
2020-04-21 09:52:52 +03:00
Denis Zharkov 12ceaf24e2 FIR: Adjust testData for spec tests: resolution ambiguity
Renaming AMBIGUITY -> OVERLOAD_RESOLUTION_AMBIGUITY may help

^KT-38342 Submitted
2020-04-21 09:52:52 +03:00
Denis Zharkov 76bb45b46f FIR: Adjust testData for spec tests: other small things 2020-04-21 09:52:52 +03:00
Denis Zharkov 7c8e2724e1 FIR: Adjust testData for spec tests: type-system 2020-04-21 09:52:52 +03:00
Denis Zharkov 2f0f552880 FIR: Adjust testData for spec tests: annotations 2020-04-21 09:52:52 +03:00
Denis Zharkov 798fe9b7d1 FIR: Adjust testData for spec tests: statements 2020-04-21 09:52:52 +03:00
Denis Zharkov 0df6354896 FIR: Adjust testData for spec tests: conditional-expressions 2020-04-21 09:52:52 +03:00
Denis Zharkov 00bf1858cc FIR: Adjust testData for spec tests: declarations 2020-04-21 09:52:52 +03:00
Denis Zharkov ee75347bb0 FIR: Adjust testData for spec tests: expressions 2020-04-21 09:52:52 +03:00
Denis Zharkov 06bae1e52f FIR: Adjust testData for spec tests: when-expression 2020-04-21 09:52:52 +03:00
Denis Zharkov 0d34299b7a FIR: Adjust testData for spec tests: dfa 2020-04-21 09:52:52 +03:00
Denis Zharkov 86e1aadd31 FIR: Adjust testData for spec tests: contracts 2020-04-21 09:52:52 +03:00
Denis Zharkov 243f9bb758 FIR: Adjust testData for spec tests: constant-literals 2020-04-21 09:52:52 +03:00
Denis Zharkov 3cb2b0cab1 Ignore irrelevant diagnostics in overload-set related spec tests 2020-04-21 09:52:52 +03:00
Denis Zharkov 0aed7375e6 Ignore irrelevant diagnostics in overload-set related spec tests 2020-04-21 09:52:52 +03:00
Denis Zharkov 1d891561cf Fix spec tests metadata
It has been working fine on OS X with its case-independent FS
2020-04-21 09:52:52 +03:00