Dmitriy Novozhilov
a05d6da43b
Move descriptor-independent Visibilities to common modules
2020-09-04 11:42:50 +03:00
Jinseong Jeon
e8157a5488
FIR: introduce & use various comparators to sort members while de/serialization
...
#KT-41018 fixed
2020-09-03 13:55:52 +03:00
Dmitriy Novozhilov
6db8c28291
[FIR] Refactor session components initialization
...
From now all customization of session should perform via DSL which
declared in FirSessionFactory. Registration or mutation session
services from other places is prohibited
2020-09-01 12:00:12 +03:00
Dmitriy Novozhilov
a8d23c36f5
[FIR] Introduce module :fir:entrypoint and FirSessionFactory for creating sessions
2020-09-01 12:00:12 +03:00
Dmitriy Novozhilov
3379d9b619
[FIR] Extract java related effective visibility calculation to platform component
2020-09-01 12:00:11 +03:00
Dmitriy Novozhilov
ca031f7ace
[FIR] Split ResolveUtils.kt from :resolve to separate files
2020-09-01 12:00:10 +03:00
Dmitriy Novozhilov
6ace4164ff
[FIR] Split TypeUtils from :resolve to :cones and :tree modules
2020-09-01 12:00:10 +03:00
Mikhail Glukhikh
5384ccf02f
[FIR] Introduce & use FirDelegatedMemberScope
2020-08-31 14:31:56 +03:00
Mikhail Glukhikh
f0af930288
[FIR] Eliminate unused FirDelegatedTypeRef
2020-08-31 14:31:56 +03:00
Dmitriy Novozhilov
b21a0213df
[NI] Get rid of FE 1.0 types in AbstractTypeApproximator
2020-08-28 10:59:51 +03:00
Mikhail Glukhikh
962059a878
Introduce FirProperty.hasBackingField & use it in FIR2IR
2020-08-25 19:29:58 +03:00
Mikhail Glukhikh
c6417696cf
FirProperty: return back 'isReferredViaField' attribute
2020-08-25 19:29:58 +03:00
Jinseong Jeon
3e9ac75cfc
FIR: record use of backing field symbol to indeed add a backing field
2020-08-25 19:29:58 +03:00
Arsen Nagdalian
6c06008b4d
[FIR] Add a class representing the old syntax contract description in order to use the previous class for the new syntax
2020-08-25 12:58:37 +03:00
Arsen Nagdalian
b83aa88eff
[FIR] Add function for getting ConeEffectDeclaration from FirEffectDeclaration and use it where needed
2020-08-25 12:58:35 +03:00
Arsen Nagdalian
991b18fec4
[FIR] Add a Fir node that wraps a ConeEffectDeclaration
2020-08-25 12:58:35 +03:00
Dmitriy Novozhilov
bc1b6d3588
Rename :core:descriptors.common to :core:compiler.common
2020-08-25 10:41:34 +03:00
Dmitriy Novozhilov
5fa80a2f8c
Merge :core:deserialization:deserialization.common into :core:descriptors.common
2020-08-25 10:41:34 +03:00
Dmitriy Novozhilov
2760a187a9
Move FunctionClassKind utils to :core.descriptors.common
2020-08-25 10:41:33 +03:00
Dmitriy Novozhilov
7d4349edc2
[FIR] Remove dependency on descriptors from :compiler:fir:tree module
2020-08-25 10:41:32 +03:00
Dmitriy Novozhilov
95346f834b
[FIR] Fix forgotten dependency to contracts of FE 1.0
2020-08-25 10:41:32 +03:00
Dmitriy Novozhilov
6f0cd14afa
Move common classes to new :core:deserialization:deserialization.common module
2020-08-25 10:31:37 +03:00
Dmitriy Novozhilov
f7f489537b
[FIR] Remove dependency on :core:descriptors from :compiler:fir:tree
2020-08-25 10:31:37 +03:00
Dmitriy Novozhilov
20a2ad8223
Move FunctionClassDescriptor.Kind to :core:descriptors.common module
2020-08-25 10:31:36 +03:00
Dmitriy Novozhilov
18ae593700
[FIR] Rename new visibilities to CamelCase
...
It's more convenient since they are objects now instead of
const fields in FE 1.0
2020-08-25 10:31:35 +03:00
Dmitriy Novozhilov
43821b681c
[FIR] Introduce new Visibility class which not depends on descriptors
2020-08-25 10:31:35 +03:00
Dmitriy Novozhilov
41ba9b0a2d
[FIR] Add flag to disable transformers required only for plugins
2020-08-25 10:31:34 +03:00
Nick
aeae898b94
[FIR] Fix issues with properties' fake sources
2020-08-24 11:06:45 +03:00
Nick
c8f8908a01
[FIR] Add NO_THIS & INSTANCE_ACCESS_BEFORE_SUPER_CALL
2020-08-24 11:06:10 +03:00
Nick
7e1c2cfd36
[FIR] Add diagnostic INAPPLICABLE_LATEINIT_MODIFIER + some builtin types
2020-08-24 11:06:06 +03:00
Jinseong Jeon
ca541337d1
FIR: skip return insertion for lambda w/ Unit return type
2020-08-21 19:16:43 +03:00
Denis Zharkov
cb6fbc329a
FIR: Simplify FirQualifiedAccess hiearchy
...
Mostly, it's getting rid of FirQualifiedAccessWithoutCallee and FirModifiableQualifiedAccess
The latter was only used during FIR building to set explicit receiver
that might be done by replace call on explicit receiver
The problem with replaceExplicitReceiver is that for FirComponentCall
explicitReceiver should be not null, so it's needed to perform those tricks
at the generatot
2020-08-21 16:34:46 +03:00
Dmitriy Novozhilov
111b8c0169
[FIR] Cleanup caching symbol in ConeClassLikeLookupTagImpl
...
Type of `boundSymbol` replaced to OneElementWeakMap
`FirSymbolProvider.getSymbolByLookupTag` moved to extensions
2020-08-21 15:27:55 +03:00
Dmitriy Novozhilov
cb0b25ea39
[FIR] Replace Deprecated with PrivateForInline in ScopeSession
2020-08-21 15:27:54 +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
Alexander Udalov
549ee84687
Fix some compiler warnings in FIR modules
2020-08-20 14:57:54 +02:00
Denis Zharkov
7f3f0faa1a
FIR: Rework overridden members processing in FirTypeScope
...
Now, FirTypeScope returns only direct overridden and a base scope
where a client might look for deeper overridden
It's necessary to make the API fast and simple
when only direct overridden are needed
At the same time, while this API looks a bit complicated for most of the clients
there are simple extension helpers that obtain just the direct or all overridden
2020-08-20 11:18:59 +03:00
Alexander Udalov
9b94e073af
Fix warnings related to OptIn/UseExperimental
2020-08-17 21:18:19 +02:00
Simon Ogorodnik
c7d6a79c25
FIR IDE: Fix completion in case of function with parameters
2020-08-17 20:05:52 +03:00
Oleg Ivanov
15598b62c9
[FIR] Add replaceControlFlowGraphReference function for FirFunction
2020-08-12 11:06:07 +03:00
Denis Zharkov
8b71f5e558
FIR: Do not leave cyclic upper bounds of type parameters
2020-08-11 10:14:02 +03:00
Ilya Kirillov
f62204fff1
FIR: move getCallableNames/getClassifierNames from scope to FirContainingNamesAwareScope
2020-08-09 12:04:52 +03:00
Ilya Kirillov
5f424ed1ec
FIR IDE: rewrite low level API
...
- Cache ModuleResolveState for module till the world changes
- Resolve every file under a lock
- All creation of raw fir files and resolve of them happens in FirFileBuilder
- Lazy resolve of fir elements happens in FirElementBuilder
Caching works like the following:
- FirModuleResolveState holds PsiToFirCache & DiagnosticsCollector & FileCacheForModuleProvider
- FileCacheForModuleProvider holds a mapping from ModuleInfo to ModuleFileCache
- ModuleFileCache caches
- KtFile -> FirFile mapping
- ClassId -> FirClassLikeDeclaration, CallableId -> FirCallableSymbol
which used in corresponding FirProvider
- mapping from declaration to it's file
which used in corresponding FirProvider
- locks for fir file resolving
- PsiToFirCache provides mapping from KtElement to FirElement
- DiagnosticsCollector collects diagnostics for file and caches them
2020-08-09 12:04:11 +03:00
Ilya Kirillov
0870ded054
FIR IDE: introduce KtFirArrayAccessReference
2020-08-09 12:03:47 +03:00
Ilya Kirillov
d10e3f91fa
FIR IDE: store FirScope strong references only in KtFirAnalysisSession
2020-08-09 12:03:33 +03:00
Roman Golyshev
6129f4bcef
Partial raw FIR building
2020-08-09 12:00:45 +03:00
Ilya Kirillov
1d92fbaa7f
FIR IDE: correctly set symbol origin for fake overridden ones
2020-08-09 12:00:24 +03:00
Ilya Kirillov
d62500531b
FIR: add getClassifierNames for FirScope
2020-08-09 11:59:57 +03:00
Roman Golyshev
656086f90a
Add FirScope::getCallableNames function
2020-08-09 11:59:50 +03:00
Nick
f15f5bccc8
[FIR] Add more diagnostic messages
2020-08-05 10:41:06 +03:00