Commit Graph

1943 Commits

Author SHA1 Message Date
Vyacheslav Gerasimov bc403ce744 Switch to 181 platform 2018-04-27 18:25:17 +03:00
Alexander Udalov dfd76502ab Minor, move serializeToByteArray to module 'metadata.jvm' 2018-04-23 18:42:33 +02:00
Alexander Udalov 361f686124 Move ModuleMapping and BinaryModuleData to metadata.jvm 2018-04-23 18:42:32 +02:00
Alexander Udalov d0544a148a Minimize dependencies of ModuleMapping
Prepare it to be moved to metadata.jvm
2018-04-23 18:42:32 +02:00
Vyacheslav Gerasimov 4299455dc1 as32: Update to AS 3.2 C10 2018-04-13 21:33:03 +03:00
Nicolay Mitropolsky c3decbb62c 181: KotlinCoreEnvironment: set ideaCompatibleBuildNumber = "181.1" 2018-04-11 16:28:27 +03:00
Ilya Gorbunov f22093ee7b as31: Comment out some new code in ClasspathRootsResolver
Relates to disabled modular JDK9 support.
2018-04-11 16:28:18 +03:00
Alexey Sedunov a9cdccc6de as31: Misc: Fix compilation 2018-04-11 16:28:18 +03:00
Nikolay Krasko 3b434eeb13 172: Restore KotlinCoreEnvironment for 172 branch
Revert "`KotlinCoreEnvironment`: set `ideaCompatibleBuildNumber = "173.1"`"
This reverts commit d3321cc77a6b55d8b8ff3c3a16473f2f3b378533.

Revert "`JvmFacade`-related tests repair"
This reverts commit faeacdd17d37a4d733b686f3a1d5e8fc6ea54d79.

Revert "Register new service and EPs added in 173"
This reverts commit 5d227c0e714c1b4316e7b8daca1f208ee423f448.
2018-04-11 16:28:02 +03:00
Anton Bannykh 703611a15c Revert "JS: remove -XtypedArraysEnabled flag (always true now)"
This reverts commit 4a5e9bb
2018-04-10 20:45:07 +03:00
Natalia Selezneva a487543827 Fix Repl System.in wrapper. Do not exit after readline in user code
^KT-23622 Fixed
2018-04-10 16:14:23 +03:00
Ilya Chernikov cc2b244484 Add a compiler option to disable default scripting plugin 2018-04-06 08:53:31 +02:00
Ilya Chernikov d05f67127d Move scripting configuration into compiler plugin 2018-04-04 16:23:55 +02:00
Ilya Chernikov d07a3f2bdd Implement script templates discovery in the cli compiler 2018-04-04 16:23:54 +02:00
Ilya Chernikov c764365da5 Add new scripting support to the compiler 2018-04-04 16:23:54 +02:00
Alexander Udalov 0439abba46 Check that kotlin.stdlib is explicitly required in module-info
Writing a Jigsaw-modular Kotlin program which doesn't require
kotlin.stdlib doesn't make sense because it most likely will fail at
runtime, on access to anything from the standard library. Previously, we
checked that kotlin.stdlib was in the module graph, but that's not
enough, we should also check that the source module requires it.
'-Xallow-kotlin-package' can be used to disable the error.

Add a test checking that an indirect (transitive) dependency is also OK
2018-04-03 21:50:25 +02:00
Mikhael Bogdanov 23e8adb793 Add custom diagnostic checker for @JvmDefault annotation 2018-04-03 19:18:17 +02:00
Alexander Udalov d0e99e9a3f Fix NPE from JarURLConnection.getUseCaches when loading compiler plugins
#KT-22513 Fixed
2018-04-03 16:55:48 +02:00
Mikhail Zarechenskiy e1d75d5581 Migration fixes for new inference 2018-03-30 20:39:55 +03:00
Alexander Udalov 46a1109910 Report warnings on usages of kotlin-stdlib-jre7/kotlin-stdlib-jre8
#KT-21347 Fixed
2018-03-26 17:19:35 +02:00
Alexey Tsvetkov 8a82c1618c Use Plugins DSL in Kotlin Gradle scripts
When plugins DSL is used, there is no need to
manually generate typesafe accessors for extensions and
conventions (by running `./gradlew kotlinDslAccessorsSnapshot`).
2018-03-26 16:09:29 +03:00
Nikolay Krasko 586860e03a Refactoring: store correspondent module info in module content 2018-03-23 18:04:01 +03:00
Nikolay Krasko 875e0a64e7 Add -Xuse-type-table to jvm compiler options 2018-03-22 11:54:01 +03:00
Alexey Tsvetkov 2584143e92 Report correct source to output mapping for kjsm files
Now IC can correctly remove kjsm files when source files are changed
2018-03-19 18:04:33 +03:00
Alexey Tsvetkov ea09f4caf6 Remove all kjsm files before writing new ones 2018-03-19 18:04:33 +03:00
Ilya Chernikov 643e81f0ae Refactor language feature settings processing for exposing it outside of the CLI compiler 2018-03-19 11:45:09 +01:00
Natalia Selezneva dcea9d0cd5 Add FATAL severity to script dependencies resolve result 2018-03-17 00:23:57 +03:00
Simon Ogorodnik c0b0f6d1ca Extract PSI to separate module 2018-03-16 13:32:14 +03:00
Alexander Udalov 27ad4f7d5d Move ProtoBuf classes to package org.jetbrains.kotlin.metadata 2018-03-14 12:25:10 +01:00
Pavel V. Talanov 32516a3f33 Refactor: split *LightClassGenerationSupport into separate files
Move cli binding trace implementation to top level
2018-03-12 12:05:05 +01:00
Pavel V. Talanov f421181e16 Split LightClassGenerationSupport into separate entities
LightClassGenerationSupport:
    Includes utilities related to generating light classes
    Primary client of this service are KtLight* implementation classes
KotlinAsJavaSupport:
    Provides APIs to transform kotlin code into Psi* entities
    Primary client of this service is JavaElementFinder
2018-03-12 12:04:59 +01:00
Yan Zhulanow fa8a3b55f3 REPL, Refactoring: A number of trivial renames/moves 2018-03-06 22:27:51 +03:00
Yan Zhulanow 82c72f228a REPL, Refactoring, Minor: Lower property visibility 2018-03-06 22:27:50 +03:00
Yan Zhulanow bceb138ed1 REPL, Refactoring: Get rid of nasty enum-like String literals 2018-03-06 22:27:49 +03:00
Yan Zhulanow 96dda8de6b REPL, Refactoring: Make ReplFromTerminal and ReplInterpreter not to implement ReplConfiguration 2018-03-06 22:27:48 +03:00
Yan Zhulanow 07363f2904 REPL, Refactoring: Replace strange callback function with an execution interceptor 2018-03-06 22:27:48 +03:00
Yan Zhulanow b35676c1bd Minor: Delete an unused class 2018-03-06 22:27:47 +03:00
Yan Zhulanow 54251ddac0 REPL, Refactoring: Rename ReplErrorLogger to ReplExceptionReporter
ReplErrorLogger is not really a class that logs errors, ReplWriter exists for that purpose (I don't think ReplWriter has a good API as well, though). The only thing it does is that is passes exceptions got from the compiler to IDE. So, in my opinion, the old name is rather confusing and it doesn't describe what the class actually do.

Also rethrow exceptions explicitly.
2018-03-06 22:27:45 +03:00
Pavel V. Talanov 27d7bb595f CliLightClassGenerationSupport: correctly find facade files
This fixes a problem where JvmPackageName annotation could force file
    facades to be in the package different to declared kotlin package
2018-03-06 12:07:12 +01:00
Yan Zhulanow 8dad2d30f5 Move the compiler.xml back to IDEA (this fixes almost all IDE tests when running on JPS) 2018-03-02 03:15:18 +03:00
Yan Zhulanow 34d1611ed4 Add Pill support to compiler and IDE modules 2018-03-02 03:15:17 +03:00
Yan Zhulanow 0ebcd0ad40 Remove inline function usages that break JPS compilation 2018-03-01 21:30:51 +03:00
Anton Bannykh 4a5e9bbc7f JS: remove -XtypedArraysEnabled flag (always true now) 2018-03-01 14:26:13 +03:00
Anton Bannykh ed80252ba8 JS: fix double compareTo behaviour for NaN and +-0 (KT-22723) 2018-02-28 15:01:58 +03:00
Mikhail Glukhikh bd0cbb716c Rename: analyzeWithDeclarations --> analyzeWithContent() 2018-02-20 20:25:41 +03:00
Mikhail Glukhikh cd1745d354 Light classes: analyzeFully() --> analyzeWithDeclarations() 2018-02-20 20:25:41 +03:00
Alexander Udalov a2835fe0d3 Do not report old runtime warnings for unstable API version
These warnings are technically correct but are too noisy and have little
value in case a user explicitly specifies unstable API version: it's
unlikely that seeing these warnings, the user will choose to rollback to
an earlier API version, since new API is probably one of the reasons
that user specified that unstable version to begin with.

So, in "kotlinc -language-version 1.3 -api-version 1.3 -cp
kotlin-stdlib-1.2.jar", we will no longer report a warning that the
attached stdlib has a version older than explicit API version (so long
as 1.3 remains unstable).

Note that we _could_ have reported these warnings in "kotlinc
-language-version 1.3 -cp kotlin-stdlib-1.2.jar", because in this case
the user might've not even be concerned with the new API in 1.3 and was
only looking for new language features. However, we still think that
it'd be unnecessary and one opt-in to the experimental world (with
LV=1.3 in this case) is enough

 #KT-22777 Fixed
2018-02-15 17:30:50 +01:00
Alexander Udalov 007248620c Disable API version inference when "-language-version" is specified
API version inference happens in
JvmRuntimeVersionsConsistencyChecker.checkCompilerClasspathConsistency
only in the case when API version is specified explicitly (with
"-api-version ..."). However, if the user specifies "-language-version
1.3", what's likely meant is "-language-version 1.3 -api-version 1.3",
and it would be unwise to infer API version to 1.2 (which is the version
of the attached stdlib) in this case.

Therefore, API version is now considered to be specified explicitly if
_either_ -language-version or -api-version is specified on the command
line

 #KT-22777 In Progress
2018-02-15 17:30:42 +01:00
Alexander Udalov 3f6aeb6dca Refactor API version inference/checking code
The behavior is not changed in this commit
2018-02-15 17:30:01 +01:00
Alexander Udalov 749773aa36 Remove -Xskip-runtime-version-check from error messages 2018-02-15 17:28:47 +01:00