Dmitry Petrov
89e1941dfd
Update testData for argument nullability assertion tests
2019-12-06 11:03:06 +03:00
Dmitry Petrov
fc7783c7dd
JVM_IR: JvmArgumentNullabilityAssertionsLowering
2019-12-06 11:03:06 +03:00
Dmitry Petrov
c676b58c14
Minor: JvmBuiltinOptimizationLowering.kt: reformat & fix warnings
2019-12-06 11:03:06 +03:00
Dmitry Petrov
20fb519f1a
PSI2IR: Generate IMPLICIT_NOTNULL casts for platform type values
2019-12-06 11:03:06 +03:00
Abduqodiri Qurbonzoda
dabf6376db
Update js reachable nodes count after expanding StringBuilder api
2019-12-06 05:37:09 +03:00
Nicolay Mitropolsky
df3bee3038
Annotations: support injections in string arrays (KT-35222)
2019-12-05 19:31:57 +03:00
Mikhail Glukhikh
f82fe20d43
[FIR] fix test data according to last commits
2019-12-05 18:27:47 +03:00
Mikhail Glukhikh
53935db992
[FIR] fix compilation error (arose due to commit conflict)
2019-12-05 18:25:17 +03:00
Dmitriy Novozhilov
6f222edb88
[FIR] Add unresolved type counter to html dump
2019-12-05 18:17:13 +03:00
Mikhail Glukhikh
bef344b33e
Optimization / clarifying: getFirClassifierContainerFile
2019-12-05 18:02:04 +03:00
Mikhail Glukhikh
2f3618041b
FIR resolve: eliminate CallInfo.containingDeclaration as unused
...
This also fixes potential KNPE during its calculation
2019-12-05 18:02:04 +03:00
Mikhail Glukhikh
c1789a0ecc
FIR IDE: synchronous creation/registration of sessions
2019-12-05 18:02:04 +03:00
Mikhail Glukhikh
70fa12d9d2
Extract FirDiagnosticsCollector to have creation logic in one place
2019-12-05 18:02:03 +03:00
Mikhail Glukhikh
9782ec1b1e
FIR resolve phases: set BODY_RESOLVE phased properly
...
Before this commit, we never set this phase to declaration or file
2019-12-05 18:02:03 +03:00
Mikhail Glukhikh
26ee02ed02
FIR: replace resolve phase in FirFile properly
2019-12-05 18:02:03 +03:00
Mikhail Glukhikh
1539ee30ff
FIR IDE: fix local class containing file search
2019-12-05 18:02:03 +03:00
Mikhail Glukhikh
d35a26a75b
Optimization: introduce FirIdeResolveStateService to cache FirResolveState
2019-12-05 18:02:02 +03:00
Mikhail Glukhikh
b4760bcbd3
Extract AbstractResolveElementCacheTest to use in FIR cache testing
2019-12-05 18:02:02 +03:00
Mikhail Glukhikh
74a7a8c881
FIR resolve (minor): provide source element for resolved qualifier
2019-12-05 18:02:02 +03:00
Mikhail Glukhikh
8808c775a4
Introduce FirResolvedTypeRef.delegatedTypeRef to see children types in IDE
...
This is needed to have access to resolved children types (e.g. type arguments) from IDE
2019-12-05 18:02:02 +03:00
Dmitriy Novozhilov
38c1a50c1d
[FIR] Resolve delegating constructor calls
2019-12-05 17:47:15 +03:00
Dmitriy Novozhilov
de77bd526b
[FIR] Change default visibility for sealed class constructors from private to public
2019-12-05 17:47:15 +03:00
Dmitriy Novozhilov
d840671620
[FIR] Don't create delegating super constructor call to kotlin.Enum for enums
2019-12-05 17:47:14 +03:00
Dmitriy Novozhilov
a0d8e5bde7
[FIR] Don't create delegating constructor call to kotlin.Annotation
2019-12-05 17:47:14 +03:00
Dmitriy Novozhilov
25720e20f4
[FIR] Fix bug in defining of completion mode
2019-12-05 17:46:59 +03:00
Dmitriy Novozhilov
088a949403
[FIR] Add implicit type counter to html dump
2019-12-05 17:46:59 +03:00
Denis Zharkov
e58711cde3
FIR: Select most specific members from supertypes scope
2019-12-05 17:35:33 +03:00
Denis Zharkov
e5166e0e7d
FIR: Extract common parts in FirSuperTypeScope
2019-12-05 17:35:33 +03:00
Denis Zharkov
43aa1f87df
FIR: Optimize supertypes scope structure
2019-12-05 17:35:33 +03:00
Denis Zharkov
91fce215d2
FIR: Simplify super type scopes related code
...
- Get rid of unnecessary subclass
- Use more abstract type where possible
2019-12-05 17:35:33 +03:00
Denis Zharkov
b8984d154b
FIR: Do not copy type parameters from class to constructors
...
Use the same instances from class declaration instead
Otherwise, primary constructor value parameter types when used
in the class body are considered as different from types
based on the class type parameters
See the test genericConstructors.kt, before this commit
"id" call was reported in inapplicable
2019-12-05 13:08:51 +03:00
Abduqodiri Qurbonzoda
20d02dd0ee
Commonize StringBuilder
2019-12-04 22:15:33 +03:00
Abduqodiri Qurbonzoda
1431e27a7b
Move StringBuilder to its own file
2019-12-04 22:15:33 +03:00
Abduqodiri Qurbonzoda
0c033297a8
Move Appendable to its own file
2019-12-04 22:15:33 +03:00
Abduqodiri Qurbonzoda
50752d47fe
Move CharacterCodingException to its own file
2019-12-04 22:15:33 +03:00
Abduqodiri Qurbonzoda
956e085b22
Rename text.kt file to StringBuilderJs.kt
2019-12-04 22:15:33 +03:00
Abduqodiri Qurbonzoda
2155f1680f
Fix small mistake in CharSequence.lastIndexOf documentation
2019-12-04 22:15:33 +03:00
Georgy Bronnikov
4a0f683bea
JVM_IR: repair after switching Ir.Symbols to non-lazy table
...
Symbols referenced from Jvm>Ir.Symbols stayed unbound, hence I have
to run ExternalDeopendenciesGenerator a second time after
creating JvmBackendContext :(
2019-12-04 16:05:53 +03:00
Georgy Bronnikov
08aeed3b46
IR: do not use lazyWrapper for Ir.Symbols
...
The reason for switching from lazyWrapper to SymbolTable itself is that
(at least in JS_IR) some of those lazily created structures could later
be deserialized, which created conflicts.
2019-12-04 16:05:53 +03:00
Vladimir Dolzhenko
b0b04eb4cd
Use kotlin specific setting "Optimize imports on the fly" in quick fix
...
#KT-35266 Fixed
2019-12-04 11:19:19 +01:00
Denis Zharkov
be5b7adb5a
FIR: Support captured types for sub-arguments
2019-12-04 10:52:19 +03:00
Denis Zharkov
5b4e8170ae
Fix variables leaking when adding other system under transaction
2019-12-04 10:52:19 +03:00
Denis Zharkov
692442d7a2
Do not look into captured star projection as types
2019-12-04 10:52:19 +03:00
Denis Zharkov
3634d80cae
FIR: Order type variables for fixation
...
Otherwise there are subtle issues with captured types
(see FirDiagnosticsSmokeTestGenerated$Inference.testDependantOnVariance)
2019-12-04 10:52:19 +03:00
Ivan Gavrilovic
7f77cc55f3
Update the test for cleanup
...
Make sure all sources are removed before adding a new Java source,
and make assertions about stubs and kotlinc generated .class files.
2019-12-03 23:05:22 +01:00
Ivan Gavrilovic
e07b2e30e2
KT-34258: Make sure to clean up stale files even if no Kotlin sources
...
If running incrementally, even if there aren't any Kotlin sources to
compile, there could be stale output files that need to be removed. E.g
stub generation must have generated .java files removed if all Kotlin
sources are removed. Kotlin compile task will be skipped only if there
are no Kotlin sources and task run is non-incremental.
Test: KaptIncrementalIT.testRemoveAllKotlinSources
2019-12-03 23:05:21 +01:00
Sergey Igushkin
a22a60118c
Fix 'Project#afterEvaluate(Action) <...> cannot be executed' on IDE test run
...
Update kotlinx.benchmark to 0.2.0-dev-7 which contains the fix for
https://github.com/Kotlin/kotlinx-benchmark/issues/13
2019-12-03 23:57:29 +03:00
Ilya Gorbunov
edfd933348
Improve Result docs to emphasize that any Throwable exception is caught
...
#KT-33447 Fixed
2019-12-03 21:08:31 +03:00
Alexander Udalov
d84daa0a4b
JVM IR: fix value argument offset in -Xjvm-default=compatibility mode
2019-12-03 18:39:43 +01:00
Pavel Kirpichenkov
3de6289c6c
[NI] Run completion on subatoms of error calls
...
Call transformer previously ran completion of argument atoms
only for non-error candidates. This led to missing diagnostics,
i.e. from collection literal resolver.
Now arguments of calls resolved to error descriptor are completed,
with exception to not found provideDelegate calls.
provideDelegate's subatoms are not completed after failure, because
it is a part of delegate competion, which does not end with
unresolved provideDelegate.
Completing after provideDelegate failure removes constraint system
from resolved arguments, which breaks resolve for get/setValue.
^KT-33592 Fixed
2019-12-03 18:19:32 +03:00