Commit Graph

57394 Commits

Author SHA1 Message Date
Natalia Selezneva 3f451d7eaf Switch off SAM adapter conversion for constructors in completion
It is very slow in completion for build.gradle.kts because it creates SAM adapters for constructors of all imported classes
Note that those SamAdapters weren't shown in completion in any case because they were filtered by name filter (SamAdapters for constructors have <init> name)
2019-09-06 10:53:16 +03:00
Natalia Selezneva f7b8c7f76e Check that project isn't disposed showing notification for scripts
EA-209612 - (Scripting, Notification) assert: ComponentManagerImpl.lambda$throwAlreadyDisposed$
2019-09-06 10:53:15 +03:00
Natalia Selezneva fb01f7be5e Rename ScriptDependenciesManager to ScriptConfigurationManager 2019-09-06 10:52:59 +03:00
Natalia Selezneva fa6b5b567b Fix org.jetbrains.kotlin.idea.script.ScriptConfigurationHighlightingTestGenerated.Highlighting.testThrowingResolver 2019-09-06 10:52:30 +03:00
Natalia Selezneva 961e8c2c74 Refactor the mechanism how script configurations are updated
Introduce file attributes cache, which is only applicable when no dependencies are cached in memory cache
Refactor ScriptDependenciesCache to memory cache that is able to get configuration from cache and checks if it is up to date
Move all public methods to ScriptDependenciesManager
Introduce ScriptClassRootsManager that checks if root change event should be called after script configuration update
2019-09-06 10:52:17 +03:00
Natalia Selezneva dc46f73ecf Rewrite scripting related API to PsiFile instead of VirtualFile
There were several places where we converted virtualFile to PsiFile. This operation need a read access and may throw ProcessCanceledException,
so we want to minimize its usages in IDE
2019-09-06 10:51:26 +03:00
Sergey Rostov 5b48dcca4f ResultWithDiagnostics: remove unused equals and hashCode
They are overridden by sealed data classes
2019-09-06 09:33:33 +03:00
Mikhail Glukhikh 91f39a0ecf FIR [optimization]: eliminate some unnecessary ScopeSessions 2019-09-06 09:29:19 +03:00
Georgy Bronnikov 7ede26e8f4 IrCompileKotlinAgainstInlineKotlin tests 2019-09-06 09:19:57 +03:00
Nikolay Krasko 0807987ef7 Update 192 to release version 2019-09-05 19:39:04 +03:00
Nikolay Krasko 655e77b0dd Update lz4 for 192 in :compiler:incremental-compilation 2019-09-05 19:39:03 +03:00
Ilya Ryzhenkov 7968ecef1c Initial import of benchmarks from https://github.com/dzharkov/kotlin-compiler-benchmarks 2019-09-05 18:31:54 +03:00
Vyacheslav Gerasimov 1bd5b68b4a Build: Instrument only java tasks for main & test source sets 2019-09-05 18:31:54 +03:00
Vyacheslav Gerasimov 50eb98194a Build: Move dependencies.properties to the root build directory 2019-09-05 17:21:48 +03:00
pyos 20626e4aaf Make ReturnableBlockLowering common
and remove special handling in JVM_IR codegen.
2019-09-05 15:48:26 +02:00
Sascha Peilicke ae8c93de6a Support symlinked JAVA_HOME
When testing for the JAVA_HOME environment variable, expand potential
symlinks first. This is almost guaranteed to be the case on all modern
Linux distributions putting the JDK / JRE behind update-alternatives to
be able to select the *current* version [0], e.g. on Fedora:

  $ ls -l $JAVA_HOME
  lrwxrwxrwx. ... /usr/lib/jvm/java -> /etc/alternatives/java_sdk

[0] https://linux.die.net/man/8/update-alternatives
2019-09-05 16:36:08 +03:00
Mikhail Glukhikh 98f72e58bd FIR deserializer: use class type parameters in constructor directly
This allows calls like Pair(...) to be resolved correctly
2019-09-05 16:26:15 +03:00
Mikhail Glukhikh 6a7ebe8928 FIR substitution: do not create fake overrides if types aren't changed 2019-09-05 16:26:14 +03:00
Mikhail Glukhikh 5386cfe254 FIR2IR: support fake overridden properties 2019-09-05 16:26:14 +03:00
Mikhail Glukhikh 687db20029 FIR: support fake overrides for properties 2019-09-05 16:26:14 +03:00
Mikhail Glukhikh 5741ff5d86 FIR: split default importing scopes into low/high priority ones
This fixes resolve of StringBuilder(), AssertionError(), etc.
2019-09-05 16:26:14 +03:00
Mikhail Glukhikh 044dfd14ce FIR: more accurate type checking in typeFromCallee 2019-09-05 16:26:06 +03:00
Ilya Goncharov c27ed0cfd3 Update ReadMe for gradle-plugin-integration-tests 2019-09-05 14:37:00 +03:00
Nikolay Krasko 5deaca9ace Fix building tests for fir:lightTree in 192 branch 2019-09-05 14:35:17 +03:00
Nikolay Krasko 7bdde7cad3 Disable HierarchicalMultiplatformProjectImportingTest in Android Studio (KT-33067) 2019-09-05 14:35:17 +03:00
Andrey Uskov 48d666daea Make platforms order reproducible in iml-files
#KT-33316 Fixed
2019-09-05 14:14:33 +03:00
Dmitry Gridin a843c23f20 Completion: add root prefix support
#KT-10340 Fixed
2019-09-05 18:01:23 +07:00
Dmitry Gridin 7a4c3e4d6a BaseDeclarationInsertHandler: fix startOffset 2019-09-05 18:01:23 +07:00
Dmitry Gridin c4a1101600 KtSimpleNameReference: add root prefix support to bindToFqName function 2019-09-05 18:01:23 +07:00
Dmitry Gridin 2e781a7a27 KtSimpleNameReference: cleanup code 2019-09-05 18:01:22 +07:00
Dmitry Gridin dd2bd320ba ShortenReferences: add root prefix support
#KT-9204 Fixed
2019-09-05 18:01:22 +07:00
Dmitry Gridin 0c81173b71 idea-core.Utils: add extension to FqName to support root prefix 2019-09-05 18:01:22 +07:00
Dmitry Gridin 953aaadee1 idea-core.Utils: cleanup code 2019-09-05 18:01:22 +07:00
Dmitry Gridin 14ad6284d9 QualifiedExpressionResolver: add root prefix resolve for IDE analysis 2019-09-05 18:01:22 +07:00
Dmitry Gridin 68d20dae66 QualifierExpressionResolver: cleanup code 2019-09-05 18:01:22 +07:00
Dmitry Gridin 4224d109e2 AnalysisFlags: add flag ideMode for IDE specific analysis 2019-09-05 18:01:22 +07:00
Andrey Uskov 106452b5f0 Add list of modules available via dependsOn in FacetSettings 2019-09-05 13:58:58 +03:00
Andrey Uskov 4642127c28 Introduce versioning of multiplatform in KotlinFacetSettings 2019-09-05 13:58:51 +03:00
Mads Ager 75f9532959 [IR] Avoid duplicate IR elements in for loops lowering. 2019-09-05 11:33:26 +02:00
Sebastian Schuberth 4ce6a54236 YarnSetupTask: Fix setup() to be a Gradle TaskAction 2019-09-05 11:30:22 +03:00
Roman Artemev 0040298eac Fix master
- improve assertion message
 - compare correct file paths
 - fix C JS BE testData
2019-09-04 14:37:14 +03:00
Roman Golyshev 870dbd158c KT-28910: Add tooltips for toolbar checkboxes in .kts scratch editor
- make `ScratchFileAutoRunner.AUTO_RUN_DELAY_IN_SECONDS` public
- remove `Show preview only` mode button from the toolbar
- ^KT-28910 Fixed
2019-09-04 10:56:41 +03:00
Roman Golyshev f0f2fd5684 KT-28910: Extract labels from scratch editor to KotlinBundle messages 2019-09-04 10:56:41 +03:00
Ilya Chernikov 72b68ee683 Fix proguarding of jline library in compiler
#KT-32234 fixed
#KT-32259 fixed
2019-09-04 09:35:04 +02:00
Mads Ager 3f28b71509 [IR] Fix issue getting the length property from CharSequence bounded type parameter
Use the class of the subtype of CharSequence when available. When
it is not (for type parameters bounded by CharSequence) call the
CharSequence getter and 'get' method. Using the most specific type
posible fixes the forInStringSpecialized test that expects the
use of INVOKEVIRTUAL and not INVOKEINTERFACE.

Add tests for the type parameter use.
2019-09-03 20:18:03 +02:00
Alexander Udalov eb5e91d6bb Do not use typeMapper to count number of coroutine parameters in MethodInliner 2019-09-03 19:33:55 +02:00
Alexander Udalov 2648fb2ddd Do not use typeMapper.mapAsmMethod for erased invoke in MethodInliner
Return type of erased `invoke` is always java/lang/Object anyway
2019-09-03 19:33:54 +02:00
Alexander Udalov 4953f67563 JVM IR: do not use KotlinTypeMapper indirectly via InlineCodegen
Move JVM signature and method owner computation out of InlineCodegen's
constructor to the call sites.
2019-09-03 19:33:54 +02:00
Alexander Udalov ad8b7ff645 Minor, extract PsiInlineCodegen to a separate file 2019-09-03 19:33:54 +02:00
Alexander Udalov bf5ca2ed84 Cleanup compiler warnings in IR-related modules 2019-09-03 19:32:57 +02:00