Dmitriy Novozhilov
1dc3c93efa
[FIR] Don't assume types with not found symbol as error types
2020-09-11 12:13:33 +03:00
Jinseong Jeon
5fdd06676f
FIR: discriminate candidates with suspend conversion
2020-09-10 11:31:24 +03:00
Jinseong Jeon
6de8ba40c1
FIR: initial support of suspend conversion on arguments
2020-09-10 11:31:24 +03:00
Victor Petukhov
685d16ec68
NI: don't do substitution for unsupported callable descriptors to use as callable references
...
^KT-41729 Fixed
2020-09-09 18:00:41 +03:00
Dmitriy Novozhilov
09ed0c3e82
[FIR-TEST] Update testdata
2020-08-28 10:59:54 +03:00
Dmitriy Novozhilov
f247cc3165
[NI] Properly detecting suitability of candidate for builder inference
...
#KT-41430 Fixed
2020-08-28 10:34:18 +03:00
Dmitriy Novozhilov
9cde42e2bc
[NI] Fix shouldRunCompletion for builder inference session
...
#KT-41308 Fixed
#KT-41363
2020-08-27 16:51:12 +03:00
Dmitriy Novozhilov
e98cbf81cf
[NI] Don't always complete builder inference lambda in FULL mode
...
#KT-41164 Fixed
2020-08-27 16:51:11 +03:00
Arsen Nagdalian
8b4e8a2c0c
Diagnostics: add diagnostic for reporting contract description blocks in old frontend
2020-08-25 12:58:39 +03:00
Nick
61e21dadec
[FIR] Add 3 type mismatch diagnostics
2020-08-24 11:06:12 +03:00
Nick
c8f8908a01
[FIR] Add NO_THIS & INSTANCE_ACCESS_BEFORE_SUPER_CALL
2020-08-24 11:06:10 +03:00
Denis Zharkov
9ac5dd2bce
FIR: Use lookup tags for as type constructors instead of symbols
...
It may help to avoid redundant symbols lookups
2020-08-21 12:50:33 +03:00
Oleg Ivanov
21b8679799
[FIR] Add ReturnsImplies effect analyzer
2020-08-12 11:06:07 +03:00
Oleg Ivanov
7da94cc299
[FIR] Fix wrong ConstantReference for returnsNotNull in EffectExtractor
2020-08-12 11:06:07 +03:00
Mikhail Zarechenskiy
2e131b870a
Add tests for obsolete issues
...
#KT-38804 Obsolete
#KT-38801 Obsolete
#KT-38835 Obsolete
#KT-38737 Obsolete
#KT-38664 Obsolete
#KT-38549 Obsolete
#KT-38766 Obsolete
#KT-38714 Obsolete
2020-08-11 12:34:02 +03:00
Dmitriy Novozhilov
0e53d11dd4
Disable AllowResultInReturnType feature
...
#KT-40843
2020-08-10 17:57:53 +03:00
Nick
4669e019d1
[FIR] Add diagnostic CONFLICTING_OVERLOADS & REDECLARATION
2020-08-10 10:09:37 +03:00
Dmitriy Novozhilov
b63257345b
[FIR] Map Class to KClass in java annotations
2020-08-04 08:59:15 +03:00
Dmitriy Novozhilov
721b9b4d8c
[FIR] Resolve annotations as calls
2020-08-04 08:59:14 +03:00
Dmitriy Novozhilov
bc1fa8ed7f
[FIR] Add constructor for java annotations
2020-08-04 08:59:14 +03:00
Mikhail Glukhikh
6eab6f2f87
[FIR TEST] Replace OTHER_ERROR with UNRESOLVED_REFERENCE in test data
2020-08-02 18:19:47 +03:00
Mikhail Glukhikh
9335e09149
[FIR] Don't report duplicated errors in implicit properties / parameters
2020-08-02 18:19:45 +03:00
Mikhail Glukhikh
749346b73b
[FIR] Don't report duplicated errors on default accessor error type refs
2020-08-02 18:19:45 +03:00
Mikhail Glukhikh
e0d25876b0
[FIR] Don't report simple diagnostics on fake sources
2020-08-02 18:19:44 +03:00
Mikhail Glukhikh
0804c6a0f3
[FIR] Introduce TYPE_ARGUMENTS_NOT_ALLOWED & some other type errors
...
This commit introduces several different things, in particular:
- check type arguments in expressions
- new TypeArgumentList node to deal with diagnostic source
- ConeDiagnostic was moved to fir:cones
- ConeIntermediateDiagnostic to use in inference (?) without reporting
- detailed diagnostics on error type
2020-08-02 18:19:44 +03:00
Nick
7145caca40
[FIR] Refactor effective visibility calculation
...
Before this commit, we had effective visibility as a part of FIR status,
so it was integrated into the full pipeline. In this commit,
we introduced "effective visibility as a service" which is now used
only by exposed visibility checker. This allows us to make the thing
universal for all FIR nodes, including nodes for Java / deserialized.
2020-07-31 19:27:58 +03:00
Ilmir Usmanov
fec845365a
Minor. No longer ignore obsolete PRE_RELEASE_CLASS diagnostic
...
in coroutine tests.
2020-07-29 17:52:01 +02:00
Dmitriy Novozhilov
f283f2db43
[FIR] Improve diagnostic reporting & don't use error symbol for candidate if possible
...
Also introduce few new diagnostics:
- NONE_APPLICABLE more many inapplicable candidates
- HIDDEN for visible candidates
2020-07-28 20:46:56 +03:00
Denis Zharkov
dc6efa5a61
Fix incorrect handling of mixed named/positional arguments
...
^KT-40404 Fixed
2020-07-24 13:36:52 +03:00
Pavel Kirpichenkov
710659324c
[NI] Fix common supertype of types with error supertypes
...
Enable check for error supertypes during CST calculation in classic type system context.
Cyclic upper bound + known type parameters of superclasses may create non-error types
with error supertypes. Such types don't have common constructors with other normal types
and cause assertion errors during intersection.
^KT-36951 Fixed
2020-07-22 11:41:42 +03:00
Denis Zharkov
037ff2fa52
Fix incorrect handling of @NotNull type parameters
...
^KT-36770 In progress
^KT-40114 Relates
^KT-28785 Relates
2020-07-22 10:16:14 +03:00
Denis Zharkov
cd896ae6c8
FIR: Implement FE 1.0 semantics for super unqualified calls
...
See original logic at org.jetbrains.kotlin.types.expressions.unqualifiedSuper.UnqualifiedSuperKt#resolveUnqualifiedSuperFromExpressionContext
^KT-39070 Fixed
^KT-39599 Related
2020-07-20 12:24:51 +03:00
Jinseong Jeon
50f1f8f0eb
FIR: consider more functional types during SAM resolution
2020-07-16 12:56:18 +03:00
Mikhail Zarechenskiy
100a6f70ca
Relax rules about inferring to Nothing for special calls
...
#KT-37388 Fixed
#KT-38427 Fixed
#KT-39953 Fixed
#KT-38899 Fixed
2020-07-16 09:56:46 +03:00
Nick
67e58ff152
[FIR] Fix redundant calls to firEffectiveVisibility()
2020-07-13 16:30:47 +03:00
Dmitriy Novozhilov
29849b1330
[FIR] Resolve rhs of += in dependent context
2020-07-08 12:13:31 +03:00
Victor Petukhov
eec3a4720c
NI: don't collect members if a receiver type is StubType to avoid creating error candidates instead of not crating them at all
...
^KT-37717 Fixed
2020-07-07 11:17:06 +03:00
Dmitriy Novozhilov
a0f8ada285
[FIR-TEST] Unmute failing diagnostic tests
2020-07-06 12:11:57 +03:00
Dmitriy Novozhilov
648953085f
[FIR] Replace kotlin/Throwable with java/lang/Throwable in JvmMappedScope
...
#KT-39044 Fixed
2020-07-02 15:10:51 +03:00
Dmitriy Novozhilov
7834284bec
[FIR] Support deserialization of value parameter annotations
...
There are still some problems, see KT-39837
2020-06-29 12:19:03 +03:00
Dmitriy Novozhilov
dbbb999952
[FIR] Support builder (coroutine) inference
...
#KT-37431 Fixed
2020-06-29 12:19:02 +03:00
Dmitriy Novozhilov
6a9504f26a
[FIR-TEST] Add coroutines diagnostic tests from old FE to FIR test suite
2020-06-29 12:19:02 +03:00
Denis Zharkov
9668a60151
FIR: Explicitlty separate static and member scopes
...
For Java, they have rather different semantics considering "overrides"
and obtaining functions/properties from supertypes
See the Java statics implementation
2020-06-26 16:52:10 +03:00
Mikhail Zarechenskiy
684ca5029f
Add tests for obsolete issues
...
#KT-37734 Obsolete
#KT-39824 Obsolete
2020-06-26 06:24:59 +03:00
Dmitriy Novozhilov
a317c8a803
[FIR-TEST] Update testdata due to unresolved KT-36056
2020-06-19 15:53:09 +03:00
Dmitriy Novozhilov
26458875d5
[FIR] Add checker for uninitialized properties
2020-06-19 15:53:09 +03:00
Mikhail Bogdanov
9c0b96af71
Report error on missed specialization in compatibility mode
...
#KT-39603 Fixed
2020-06-19 11:57:36 +02:00
Mikhail Bogdanov
477cca3c99
Add JvmDefaultWithoutCompatibility annotation
2020-06-19 11:57:35 +02:00
Victor Petukhov
982cbf1148
NI: clear calls info in coroutine inference before the second analysis of += right side
...
^KT-39376 Fixed
2020-06-16 18:26:59 +03:00
Mikhail Zarechenskiy
93e9d3e57d
Delay check for possibly deferred return type for reference candidate
...
This issue appeared after recently added new overload for flatMapTo.
Before that, we picked candidate returning List<T> and completed
inference, now we also check one more flatMapTo, which is here is
incorrect and as a result we go into outer scope. Outer scope contains
one property with deferred type, which introduced error about
"typechecker has run into recursive problem" even it isn't applicable
by receiver.
So, the fix is to check receiver first and only then check return
type of a candidate.
#KT-39470 Fixed
2020-06-09 17:36:58 +03:00