Commit Graph

43968 Commits

Author SHA1 Message Date
Ilya Gorbunov 8f78d73cd7 Use fqnames for SortedSet and TreeSet from java.util
Remove internal typealiases for SortedSet and TreeSet
2018-02-02 17:56:56 +03:00
Ilya Gorbunov b456c52902 Import kotlin.coroutines.experimental for generated sequences on all platforms
This will add import to common generated sources
2018-02-02 17:56:56 +03:00
Natalia Selezneva cdbe0b8fa9 Scratch tests: delete scratch file after creation 2018-02-02 17:44:42 +03:00
Natalia Selezneva 6ca1b10f41 Use correct logger for debugging scratch files 2018-02-02 17:44:35 +03:00
Natalia Selezneva 847990a4f6 Tests: call super.teardown from finally block in android tests 2018-02-02 17:44:28 +03:00
Vyacheslav Gerasimov 36167c7b8f Add annotations to lint plugin dependencies
Fixes `warning: unknown enum constant` during lint plugin build
2018-02-02 16:58:43 +03:00
Alexey Tsvetkov 6c4f3df851 Remove intellij-core usages from kotlin-gradle-plugin-integration-tests
We can use only relocated intellij-core from kotlin-compiler-embeddable.
Non-source usages do not resolve in IDE (which also breaks debugger).
2018-02-02 15:40:11 +03:00
Alexey Tsvetkov 8f144fc57a Fix red code in IDE in kotlin-gradle-plugin-integration-tests 2018-02-02 15:40:10 +03:00
Alexey Tsvetkov 7c329b59b6 Shade test jars from compiler used in Gradle tests
This fixes `VerifyError` for all integration tests calling
`KotlinTestUtils.findAndroidSdk()`.
The exception was thrown because `:kotlin-gradle-plugin-integration-tests`
was depending on both relocated intellij-core (from kotlin-compiler-embeddable)
and non-relocated intellij-core (transitevely through tests jars from compiler).

A call to `findAndroidSdk()` was triggering classloading
for `KotlinTestUtils` which had bytecode references to
`org.jetbrains.kotlin.idea.KotlinLanguage` loaded from the embeddable compiler
and to `com.intellij.lang.Language` loaded from non-relocated intellij-core.

`KotlinLanguage` from the embeddable compiler was a subclass of relocated
`org.jetbrains.kotlin.com.intellij.lang.Language` thus it was not
assignable to `com.intellij.lang.Language` causing `VerifyError`.

The solution is to create relocated jar combining the necessary test jars
from the compiler.
2018-02-02 15:40:10 +03:00
Alexey Tsvetkov 7cba035f80 Ensure tasks using android sdk or android jar have proper dependencies
A test task, that uses android dependency but does not depend on
a corresponding configuration, would fail when it was run after
'clean' task.
I've extracted 'useAndroidSdk', 'useAndroidJar' extensions
making it harder for a developer to forget to set up task dependencies.
2018-02-02 15:40:10 +03:00
Anton Bannykh 3ead464671 JS: fix callable reference with implicit extension receiver (KT-22638 fixed) 2018-02-02 14:34:34 +03:00
Alexander Udalov f4e2102787 Minor, remove extra empty lines from -X arguments help 2018-02-01 19:38:32 +01:00
Alexander Udalov 5338df6960 Do not depend on Shadow plugin in subprojects
Since buildSrc depends on the Shadow plugin, it's already in the
classpath of all build scripts
2018-02-01 19:38:31 +01:00
Alexander Udalov ad0cd7c176 Use the same JVM args for buildSrc as for main project 2018-02-01 19:38:30 +01:00
Alexander Udalov f9e195351a Minor, rephrase usage help for -no-stdlib/-no-reflect compiler arguments 2018-02-01 19:38:30 +01:00
Alexander Udalov 28c77bfb01 Fix kotlin.annotation.Target's kdoc
The original sentence was incorrect because it did not exclude type
aliases
2018-02-01 19:27:43 +01:00
Alexander Udalov 616ba1fbe4 Minor, remove obsolete JDK 9 EA version guard 2018-02-01 19:27:43 +01:00
Alexander Udalov efd92547ef Remove unused description file 2018-02-01 19:26:39 +01:00
Vyacheslav Gerasimov dd9ea0bc87 Remove unnecessary dependencies on :prepare:idea-plugin:idea-plugin 2018-02-01 18:11:25 +03:00
Vyacheslav Gerasimov ec511f7a78 Use dependsOn for dependencies on dist & ideaPlugin tasks
instead `shouldRunAfter`
2018-02-01 18:11:25 +03:00
Vyacheslav Gerasimov a595fdd312 Make root dist & ideaPlugin depend on all corresponding tasks in child projects 2018-02-01 18:11:25 +03:00
Alexey Tsvetkov 74e47e024f Replace testCompile with testRuntime dependencies
Compile dependencies broke incremental compilation
because packed compiler was present in idea
test compile classpath (we do not track changes in
fat jars)
2018-02-01 17:39:55 +03:00
Alexey Tsvetkov 4ee34fc355 Avoid building kotlin-compiler-embeddable before running idea tests
kotlin-compiler-embeddable is a runtimeOnly dependency of
kotlin-compiler-runner, so embeddable jar was built
before idea tests execution.
Building the jar takes ~20s on my machine, which is a waste
of time since idea does not use embeddable compiler.
2018-02-01 17:39:55 +03:00
Alexey Tsvetkov 29d2679e8d Do not configure dist task for every published module
This change avoids compiling kotlin-compiler-embeddable,
kotlin-gradle-plugin, and other gradle plugins,
when running `./gradlew dist`
2018-02-01 17:39:55 +03:00
Alexey Tsvetkov d5ee77eb07 Avoid exception when listing configuration contents 2018-02-01 17:39:54 +03:00
Alexey Sedunov f35af11423 Rename: Make improvements for "by-convention" calls
- Convert between conventions call for 'get' and 'invoke'
- Drop 'operator' when converting 'get'/'invoke' to something other than
  'invoke'/'get' respectively

 #KT-12365 Fixed
2018-02-01 15:41:09 +03:00
Alexey Sedunov caeb594e09 Rename: Replace name identifiers via AST to prevent unwanted reformatting
#KT-8563 Fixed
2018-02-01 15:41:06 +03:00
Alexey Sedunov 58bf42c1dd Rename: Support KtTypeAlias in RenameKotlinClassProcessor
#KT-21719 Fixed
2018-02-01 15:41:04 +03:00
Alexey Sedunov 90392a8d8a Loop to Call Chain: Do not generate lambda with double wrapping block
#KT-22476 Fixed
2018-02-01 15:41:03 +03:00
Alexey Sedunov 8c9c1609c0 Move Class to Top Leve: Suggest file name based on new class name
#KT-17977 Fixed
2018-02-01 15:41:01 +03:00
Alexey Sedunov 4d52bf04fe Kotlin Ultimate: Support NodeJS CLI run configuration
#KT-16710 Fixed
2018-02-01 15:35:35 +03:00
Alexey Sedunov 1f7fab837f Gradle: Import production output path for JavaScript modules 2018-02-01 15:35:34 +03:00
Alexey Sedunov 80887a84ca Kotlin Ultimate: Add "Build" action to JS run configurations
#KT-20522 Fixed
2018-02-01 15:35:34 +03:00
Ilmir Usmanov 8ffb205f1c Reformat coroutineContext related code 2018-02-01 13:18:43 +03:00
Ilmir Usmanov 18c03f94f8 Move coroutineContext to correct package
from kotlin.coroutines.experimental.instrinsics to kotlin.coroutines.experimental

 #KT-22400
2018-02-01 13:18:32 +03:00
Natalia Selezneva efabf80d37 Scratch: do not store psiFile in ScratchFile 2018-02-01 11:07:54 +03:00
Natalia Selezneva c32a7dd852 Scratch: add logging 2018-02-01 10:21:55 +03:00
Natalia Selezneva 2140b9457d Minor: fix formatting 2018-02-01 10:21:55 +03:00
Natalia Selezneva ac7beb41f3 Rearrange checkboxes in scratch panel 2018-02-01 10:21:55 +03:00
Natalia Selezneva d6d2d4271b Scratch: restore information about module in scratch panel after ide restart 2018-02-01 10:21:55 +03:00
Natalia Selezneva 0a274a7e61 Align output in scratch file 2018-02-01 10:21:55 +03:00
Natalia Selezneva 8e98f703ac Change colors for scratch output 2018-02-01 10:21:55 +03:00
Natalia Selezneva dc71ac09b2 Scratch: do not report errors from generated file to editor 2018-02-01 10:21:55 +03:00
Natalia Selezneva ad90095dc7 Show multple errors in scratch toolwindow 2018-02-01 10:21:55 +03:00
Natalia Selezneva d7c6dacc86 Temporary workaround: rename scratch files with kt extension to kts before additional api will be added in IDEA 2018-02-01 10:21:55 +03:00
Natalia Selezneva c4971de7c1 Scratch: add Make before Run checkbox 2018-02-01 10:21:55 +03:00
Natalia Selezneva a96cf147fc Scratch: add multifile tests 2018-02-01 10:21:55 +03:00
Natalia Selezneva 23ef50203e Use correct check for isRepl checkbox in scratch panel 2018-02-01 10:21:55 +03:00
Natalia Selezneva 654890fac3 Scratch: implement compiling executor 2018-02-01 10:21:55 +03:00
Natalia Selezneva dda0b38fb9 Scratch: tests for repl execution 2018-02-01 10:21:55 +03:00