Jinseong Jeon
771c839d74
FIR DFA: element-wise join at merging points of try expression
2020-11-04 16:35:42 +03:00
Jinseong Jeon
bd173ebebc
FIR DFA: isolate effects between blocks in try expression
2020-11-04 16:35:42 +03:00
Denis Zharkov
a936386e53
FIR: Add more complicated workaround for OverloadResolutionByLambdaReturnType
...
That helps for minOfOrNull/maxOfOrNull
2020-11-03 18:30:15 +03:00
Denis Zharkov
4612f26bfb
FIR: Add workaround for OverloadResolutionByLambdaReturnType
...
Mostly, that should help for existing flatMap usages
^KT-43129 Submitted
2020-11-03 18:30:15 +03:00
Victor Petukhov
7b53d668ab
Fix test after 4f06162446
2020-10-23 18:33:23 +03:00
Victor Petukhov
4f06162446
Get a callable reference expression to report an error on it properly, taking into account possible wrapping
...
^KT-42620 Fixed
2020-10-23 15:12:08 +03:00
Mikhail Glukhikh
c50aa5f2ec
[FIR TEST] Bad test data changes due to Java signature transformation
...
Both changes are related to getOrDefault. We should either make Java
version low priority or remove it at all.
2020-10-23 08:12:16 +03:00
Mikhail Glukhikh
d3e85dbce0
[FIR] Implement replacing Object with type parameters for specials builtins
...
#KT-42601 Fixed
2020-10-23 08:12:15 +03:00
Victor Petukhov
84129098cb
Add equality constraints without subtyping
...
^KT-42195 Fixed
^KT-41741 Fixed
2020-10-21 21:23:13 +03:00
Pavel Kirpichenkov
04a4f9cde6
Minor: cover negative cases with test +m
...
Add case without reported diagnostic on public companion.
Only report diagnostic if @JvmStatic annotation has source in code.
KT-25114
2020-10-16 11:11:59 +03:00
Pavel Kirpichenkov
9669ab1468
Report warning on @JvmStatic in private companion objects
...
Deprecation cycle to prohibit in 1.5.
^KT-25114 In Progress
2020-10-16 11:11:59 +03:00
Pavel Kirpichenkov
d769ca06ab
Add test for KT-25114
2020-10-16 11:11:58 +03:00
Victor Petukhov
c6da2a1138
Reuse built functional types for postponed arguments by expected types and paths from a top level type variable
...
^KT-42221 Fixed
2020-10-16 10:46:22 +03:00
Mikhael Bogdanov
c8e84f82eb
Proper check NON_JVM_DEFAULT_OVERRIDES_JAVA_DEFAULT in new jvm-default modes
...
#KT-42699 Fixed
2020-10-15 16:26:00 +02:00
Jinseong Jeon
43852ad7ab
FIR CFG: add edges from try/catch to finally
2020-10-15 14:22:39 +03:00
Pavel Kirpichenkov
39a87435ee
[FIR/NI] Refactor type variable gathering from lambda types
...
Motivation:
- drop getArguments from type context as a duplicate of getArgumentList
- reduce the number of collection allocations in getAllDeeplyRelatedTypeVariables
Additional minor improvements, test data fixes
2020-10-13 11:00:21 +03:00
Pavel Kirpichenkov
ef44077cb7
[FIR] Restore variable fixation direction in call completion
...
Several tests are affected by the usage of fixation direction calculator in FIR.
Restored to mimimize test data changes.
It is unnecessary in FE10 because a type variable with unknown type
is inferred into an error type, but affects test data in FIR where
Nothing/Any is selected by direction (as a temporary measure).
CR candidate in spec test is Unresolved in FIR because top-level CRs are resolved as call arguments.
Resolution ambiguity is also present in FE10 when CR is wrapped into an id call.
2020-10-13 11:00:21 +03:00
Victor Petukhov
d02432cf93
Introduce warning for the changing arguments execution order for named varargs (KT-17691)
2020-10-01 12:15:13 +03:00
Mikhail Glukhikh
14cfc62745
FIR: fix calculation of type arguments for bare types
2020-09-23 09:00:57 +03:00
Лихолетов Михаил
cfc1ebb4be
[FIR] Support several annotation argument diagnostics
2020-09-16 16:53:31 +03:00
Victor Petukhov
17db188b0e
Add regression test for already fixed issue KT-41396
2020-09-16 14:02:32 +03:00
Victor Petukhov
8cabfda832
Add regression test for already fixed issue KT-41885
2020-09-15 19:03:16 +03:00
Mikhail Glukhikh
cf5480a398
[FIR] Questionable test data fixes (around captured types)
2020-09-14 18:08:26 +03:00
Mikhail Glukhikh
4605a65f41
[FIR] Good test data fixes (around captured types)
2020-09-14 17:56:39 +03:00
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