Ivan Kochurkin
a0510f4a67
[FIR] Fixed Replace ConeTypeVariable on ConeTypeParameter ^KT-51017
...
in AbstractConeCallConflictResolver.computeParameterTypes
2022-02-07 17:21:59 +03:00
Mads Ager
a398f7d6cb
Rename kt-reference module to kt-references.
2022-02-07 15:01:24 +01:00
Mads Ager
17aee1e944
Move frontend independent parts of KtReference.isReferenceTo up to share it.
2022-02-07 15:01:24 +01:00
Mads Ager
6f0bb0eda5
Add analysis:kt-reference module and move KtReferences there.
2022-02-07 15:01:23 +01:00
Dmitriy Novozhilov
aadfc59d0f
[FIR] Complete delegated constructor calls without proper constructed type
...
This is needed to definitely complete arguments of such calls
2022-02-07 13:36:38 +03:00
Dmitriy Novozhilov
1591518cf6
[FIR] Support constant unary operators for integer literal operators
...
^KT-38895
2022-02-07 13:36:37 +03:00
Dmitriy Novozhilov
52b72a7dac
[FIR] Implement Int -> Long conversions for literals and operators over them
...
^KT-38895
^KT-50996 Fixed
^KT-51000 Fixed
^KT-51003 Fixed
^KT-51018 Fixed
2022-02-07 13:36:36 +03:00
Dmitriy Novozhilov
b980f5ab32
[FIR] Introduce new kind of integer literal types for constant operator calls
2022-02-07 13:36:35 +03:00
Dmitriy Novozhilov
0bd3e8f418
[FIR] Rename ConeClassErrorType to ConeErrorType, drop ConeKotlinErrorType alias
2022-02-07 13:36:33 +03:00
Roman Golyshev
7c9000b8ac
[FIR IDE] Consider FirFileSymbol in KtSymbolByFirBuilder.buildSymbol
2022-02-06 15:29:54 +03:00
Pavel Kirpichenkov
90abbb4a9f
[MPP] Add test for inc/dec check in expect class
...
KT-49714
2022-02-04 16:57:21 +03:00
Mikhail Glukhikh
81ff9b820a
FIR: make ConeSimpleKotlinType the only original for definitely not-null
2022-02-03 19:12:16 +03:00
Roman Golyshev
7e1a9e2b9a
KTIJ-20637 Group files by module in getFacadeClassesInPackage also
...
Fixup for 35e2561dab , since these changes
were overlooked in the initial commit.
^KTIJ-20637 Fixed
2022-02-02 19:02:23 +03:00
Dmitriy Novozhilov
e544c404b9
[FIR] Fix error message for CONFLICTING_INHERITED_MEMBERS
2022-02-02 10:55:40 +03:00
Roman Golyshev
35e2561dab
KTIJ-20637 Group files by module and create facade class for each one
...
Before all files were going to `getOrCreateSymbolLightFacade`. If there
were both compiled and source files, it caused exceptions later
(see `SymbolLightClassFacadeCache.getOrCreateFirLightFacadeNoCache`).
When grouped by the `KtModule`, each file group should contain either
only sources or only compiled classes.
^KTIJ-20637 Fixed
2022-02-01 22:00:51 +03:00
Ilya Kirillov
b8c36b7998
Analysis API FIR: remove compilation errors from new testdata
2022-02-01 16:31:29 +01:00
Ilya Kirillov
441de5cd75
Analysis API FIR: resolve Java synthetic properties KtSyntheticJavaPropertySymbol
2022-02-01 16:31:28 +01:00
Ilya Kirillov
dcbf84771d
Analysis API: regenerate tests
2022-02-01 16:31:27 +01:00
Mads Ager
d13e117a58
Change FIR analysis API resolution for super type calls.
...
The IDE expects the super type calls to resolve to the constructor
invoked and not the class. The frontend itself resolves to the
class, so an extra layer is needed to adjust that to the constructor.
2022-02-01 16:31:26 +01:00
Denis.Zharkov
772579143b
FIR: Change semantics for combination of safe calls and operators
...
^KT-41034 Fixed
2022-02-01 13:12:49 +03:00
Denis.Zharkov
6f89f1ebf4
FIR: Allow selector of safe calls to be a FirStatement
...
It's necessary to allow a?.b += v be interpreted as a?.(b += v)
But currently FirAssignmentOperatorStatement is not FirQualifiedAccess
^KT-41034 In Progress
2022-02-01 13:12:45 +03:00
Ilya Kirillov
6e999f6e84
LL API: refactoring: replace FirIDE prefixes with LLFir prefixes
2022-01-31 21:12:31 +01:00
Ilya Kirillov
4530041cbb
Analysis API: move reference resolve testsdata with errors to dedicated folders
2022-01-31 21:12:30 +01:00
Ilya Kirillov
caddbda01b
Analysis API FIR: introduce library resolve tests
2022-01-31 21:11:56 +01:00
Ilya Kirillov
96e1f1e7d4
Analysis API: fix some compilation errors in reference resolve testdata
2022-01-31 21:11:54 +01:00
Ilya Kirillov
d926dda27f
Analysis API FIR: introduce declarations from library resolve
...
^KT-50252 fixed
2022-01-31 21:11:52 +01:00
Ilya Kirillov
d9200affe4
LL API: simplify FirModuleResolveState interface
2022-01-31 21:11:51 +01:00
Mikhail Glukhikh
1137e61fc8
FIR: add test for KT-50969
2022-01-31 21:59:15 +03:00
Roman Golyshev
bc3142f4da
Remove accidentally copied testData file
2022-01-29 07:42:18 +00:00
Roman Golyshev
f0f2f67024
KT-50862 Unwrap use-site substitution overrides
...
Use-site substitution override happens in situations like this:
```
interface List<A> { fun get(i: Int): A }
fun take(list: List<String>) {
list.get(10) // this call
}
```
We want to have those overrides unwrapped, because we don't want
to deal with a different KtSymbol for each possible use-site
^KT-50862 Fixed
2022-01-29 07:42:18 +00:00
Roman Golyshev
564e408434
KT-50862 Add name property to KtSignature
...
See the KDoc of the property for the reasons why
it was created
2022-01-29 07:42:17 +00:00
Mikhail Glukhikh
c2f43dd98e
Revert OPT_IN_MARKER_ON_OVERRIDE limitation #KT-48890 Fixed
2022-01-28 13:40:35 +00:00
Mikhail Glukhikh
c2ab09fa84
Add test for KT-49653
2022-01-27 17:27:38 +03:00
Roman Golyshev
9ff46004e4
FIR IDE: Remove typesCache from KtSymbolByFirBuilder
...
This cache wasn't working too well, because ConeTypes have
equals/hashCode implementations which do not account for types'
attributes (like annotations, for example).
Because of that, `String` and `@Annotated String` were considered the
same type, and the cache was remembering whichever came first.
2022-01-27 16:23:44 +03:00
Victor Petukhov
1a23cd8c45
[FE 1.0] Don't try to report specialized resolution ambiguity error for builder inference if the corresponding substitutor is empty
...
^KT-50989 Fixed
2022-01-27 15:30:16 +03:00
Ilya Muradyan
9637b6b848
REPL: Fix REPL scripts metadata to be correctly recognized by class file decompiler
2022-01-27 02:23:27 +03:00
Mikhail Glukhikh
ad0d0ca47f
Drop redundant Suppress("RemoveExplicitTypeArguments")
2022-01-26 12:19:55 +00:00
Roman Golyshev
8befbc6375
KTIJ-20826 Approximate builder inference stub types as type parameters
...
This is a temporary fix to avoid crashes in FIR IDE
Of all stub types, only `ConeStubTypeForChainInference` is handled now,
so we can catch the other possible errors with stub types (in the
delegates' inference, for example)
The fix introduced in this commit should be reworked when KT-50916 is
fixed
^KTIJ-20826 Fixed
2022-01-25 17:09:03 +03:00
Dmitriy Novozhilov
d1fb8338ef
[FIR] Infer type of elvis from lhs if rhs is Nothing
...
^KT-50875 Fixed
2022-01-23 08:22:07 +03:00
Ivan Kochurkin
defb0cf611
[FIR] Fix ambiguity between Sequence.forEach and Iterable.forEach (with @HidesMembers) ^KT-50776 Fixed
2022-01-21 19:34:10 +03:00
Ilya Kirillov
d74418f575
LL API: remove old resolve api
2022-01-21 16:46:40 +01:00
Ilya Kirillov
6dd01a2ff5
LL API: do not lazy resolve local declarations
2022-01-21 16:46:39 +01:00
Ilya Kirillov
c7729689c4
LL API: always create FirFile with lazy bodies
2022-01-21 16:46:38 +01:00
Ilya Kirillov
75ae37fcbf
LL API: remove unused resolve api
2022-01-21 16:46:36 +01:00
Ilya Kirillov
7a0d1ce0d1
LL API: consider enum entries as structure elements
2022-01-21 16:46:30 +01:00
Ilya Kirillov
e1fece6402
Analysis API: fix testdata of reference resolve tests which started to pass
2022-01-21 16:46:28 +01:00
Ilya Kirillov
16fbc09997
Analysis API: use FirSymbol in KtFirSymbol's instead of FirDeclaration
...
^KT-50271 fixed
2022-01-21 16:46:27 +01:00
Mikhail Glukhikh
98cdc95cd0
FIR DFA: exit delegate expression only after accessor completion
...
This commit fixes DFA problem (see test) when we accidentally try
to merge incoming flows from member property (val ... by cached ...) and
the following function. While completing lambda of buildList { ... }
inside by cached we accidentally assume that delegate is already left
and add the lambda into exitsFromCompletedPostponedAnonymousFunction.
This commit fixes the problem by exiting delegate later, after completion.
2022-01-20 23:46:39 +03:00
Mikhail Glukhikh
d2bfb7153e
Add test from KT-49925 (example 3, fails yet)
2022-01-20 23:46:35 +03:00
Ilya Kirillov
3b943706d8
Analysis API: fix call resolve inside plusAssign target
...
^KT-50864 fixed
2022-01-20 23:26:28 +03:00