Commit Graph

105 Commits

Author SHA1 Message Date
Abduqodiri Qurbonzoda 80b48eed0b Fix Path.copyToRecursively when copying across file systems #KT-55935
Merge-request: KT-MR-8705
Merged-by: Abduqodiri Qurbonzoda <abduqodiri.qurbonzoda@jetbrains.com>
2023-02-07 08:25:54 +00:00
Ilya Gorbunov b558382f17 Cleanup unneeded options in kotlin-stdlib-jdk7/8 compilations 2023-01-26 20:57:00 +00:00
Ilya Gorbunov 5a4eb22961 Move isolated addSuppressed extension test to jvm tests
Conditions for being isolated do not hold anymore:
it tested that addSuppressed extension could work without kotlin-stdlib-jdk7,
but now the latter is merged to kotlin-stdlib and thus always present

#KT-51907
2023-01-26 20:57:00 +00:00
Ilya Gorbunov 8b68234528 Include all jvm stdlib tests into kotlin-stdlib project test
JVM stdlib tests are compiled against JDK 8 so there's no need to divide them by modules anymore

#KT-51907
2023-01-26 20:57:00 +00:00
Abduqodiri Qurbonzoda ba2833b90f Mark Base64 API with ExperimentalEncodingApi 2023-01-16 11:24:50 +00:00
Abduqodiri Qurbonzoda fff593492d Introduce Common AutoCloseable & use #KT-31066
Co-authored-by: Ilya Gorbunov <Ilya.Gorbunov@jetbrains.com>

Merge-request: KT-MR-8113
Merged-by: Abduqodiri Qurbonzoda <abduqodiri.qurbonzoda@jetbrains.com>
2022-12-27 11:50:22 +00:00
Abduqodiri Qurbonzoda f38654740e Use Path.deleteRecursively() in the Path.cleanupRecursively() test util 2022-09-18 22:49:02 +00:00
Abduqodiri Qurbonzoda 90189f9c39 Provide Path.copyToRecursively() and Path.deleteRecursively() #KT-52928 2022-09-18 22:49:01 +00:00
Abduqodiri Qurbonzoda 7271de2642 Test Path.copyTo when source and target paths are the same file 2022-09-18 22:49:01 +00:00
Abduqodiri Qurbonzoda 6fde3391d3 Test that Path.copyTo() does not follow symlink in destination 2022-09-18 22:49:01 +00:00
Abduqodiri Qurbonzoda 6ddb0326bb Test that Path.copyTo() copies the source file access permissions 2022-09-18 22:49:01 +00:00
Abduqodiri Qurbonzoda f0da420b1f Move Path.tryCreateSymbolicLinkTo to AbstractPathTest.kt 2022-09-18 22:49:00 +00:00
Ilya Gorbunov 18e4d9e16c Deprecate modules of the empty artifacts to discourage their usage
#KT-51907
2022-09-15 15:38:33 +00:00
Ilya Gorbunov 1b6a462057 Move contents of stdlib-jdk7/8 into stdlib
#KT-51907
2022-09-15 15:38:32 +00:00
Abduqodiri Qurbonzoda f3e8816dc3 Do not generate JVM 1.8+ annotation targets in stdlib, -jdk7, -jdk8, reflect
See #KT-53712
2022-09-02 14:59:24 +00:00
Ilya Gorbunov 12d3ef41dc Use older JDK toolchains for compiling stdlib and stdlib-jdk7
To prevent using newer JDK API in kotlin sources of these projects.
Note that java sources (of stdlib mainly) are still compiled with JDK 8.

#KT-51907
2022-09-01 16:52:36 +00:00
Abduqodiri Qurbonzoda 6c4777dcdd Fix JDK-dependent stdlib tests after advancing jvmTarget 2022-08-17 22:55:43 +03:00
Abduqodiri Qurbonzoda eb3bbc3265 Remove "-Xsuppress-deprecated-jvm-target-warning" compiler argument 2022-08-13 01:48:23 +03:00
Abduqodiri Qurbonzoda 34e50649e8 Switch JVM target of the standard libraries to 1.8 #KT-51907 2022-08-13 01:33:45 +03:00
Abduqodiri Qurbonzoda 78666e3ecb Provide visit extension functions for java.nio.file.Path #KT-52910 2022-06-28 00:52:43 +00:00
Abduqodiri Qurbonzoda e7b37b3497 Implement a walk extension function for java.nio.file.Path #KT-52909 2022-06-28 00:52:42 +00:00
Ilya Gorbunov cd9b36b4c3 Introduce OpenEndRange and make primitive ranges implement it
#KT-52932
2022-06-28 00:08:03 +00:00
Yahor Berdnikau af6f17c243 Unify kotlinCompilerClasspath for all projects
This will prevent spawning second Kotlin daemon during compilation
except 'buildSrc' compilation. Original change was introduced in
2e515f3945 commit.
2022-05-24 07:58:38 +00:00
Alexander Udalov 2e515f3945 Prohibit JVM target 1.6
But still compile stdlib, reflect, kotlin.test and scripting runtimes
with JVM target 1.6 to simplify migration from Kotlin 1.6 to 1.7.

 #KT-45165 Fixed
2022-04-19 22:54:40 +02:00
Alexander Likhachev 64aae756d1 [Build] Avoid project usages in jdk6 tests
#KT-44611 In Progress
2022-04-19 00:39:24 +03:00
Ilya Gorbunov 2954769296 KT-50059 Stop publishing artifacts with 'modular' classifier 2021-12-29 17:43:56 +00:00
Ilya Gorbunov eba6a4a000 KT-44089 Reflect Android SDK version to determine whether platform implementatoins are eligible
SDK version sanity check, suppress all reflection errors, duplicate SDK reflection code for more robustness
2021-12-06 12:24:45 +03:00
Vyacheslav Gerasimov ab146bd6d4 Build: Fix deprecated Gradle configurations usages
for migration to Gradle 7+ #KTI-559
2021-09-26 18:28:44 +03:00
Dmitriy Novozhilov 0923d39215 [Build] Setup useFirForLibraries flag 2021-09-20 14:18:18 +03:00
Mikhail Glukhikh ffbd574a08 Use -opt-in instead of -Xopt-in in comments and scripts 2021-09-08 23:43:55 +03:00
Alexander Udalov 3bc0eaff59 Fix warnings in stdlib samples and test modules 2021-08-10 17:57:50 +02:00
Alexander Udalov 0925e1b497 Enable JVM IR for stdlib/reflect/test libraries
Changes in Gradle integration tests are needed because:
- in new-mpp-android, kotlin-stdlib-jdk8 is used, and JVM IR generates
  JDK 8-specific bytecode (invokedynamic). D8 needs to be configured to
  desugar it with source/target versions set to 1.8, otherwise it
  reports an error.
- in AndroidExtensionsManyVariants and AndroidIcepickProject, D8 fails
  with assertions enabled if AGP < 4.0.0 is used because of
  https://issuetracker.google.com/issues/148661132. The tests which use
  old AGP versions are probably not relevant anymore anyway.

Changes in kotlin-stdlib-runtime-merged.txt are caused by a slightly
different generation scheme of collection subclasses in JVM IR, and are
harmless.

(Previous attempt was at 15e978dbd311c2ba78ec32b394c21acde9811ccb.)
2021-08-05 12:36:35 +02:00
Alexander Udalov 0a9498f7e2 Build: suppress deprecated JVM target warning globally
There seems to be no point in configuring the compiler argument per
project. This argument will be deleted soon anyway, when we remove
support for JDK 1.6 & 1.7.

Also remove `disableDeprecatedJvmTargetWarning`. It didn't have any
effect in all modules where it was applied because these modules
reassign `freeCompilerArgs` anyway, with
`-Xsuppress-deprecated-jvm-target-warning` in it.
2021-07-27 13:35:39 +02:00
Alexander Udalov 91c39ed01c Build: remove obsolete compiler arguments
These compiler arguments enable features which are enabled by default in
the current Kotlin anyway.

The only exception is in :compiler:cli which uses an old language
version.
2021-07-27 13:35:38 +02:00
Yahor Berdnikau 7789054547 Migrate repo to use JVM toolchains Gradle feature.
^KT-46972 Fixed
2021-07-05 14:11:12 +00:00
Yahor Berdnikau 08d831934a Revert "Build: add temporary option to suppress jdkHome warning"
This reverts commit 1dfcec3a93.
2021-07-05 14:11:11 +00:00
Alexander Udalov 1dfcec3a93 Build: add temporary option to suppress jdkHome warning 2021-05-28 15:41:17 +02:00
Ilya Gorbunov 81f2aea316 Stabilize existing Path API and annotate with @Throws where appropriate
KT-45913
2021-04-06 14:24:42 +03:00
Alexander Udalov e0b6d4d917 Add -Xsuppress-deprecated-jvm-target-warning to modules compiled with 1.6
Currently this leads to an unknown argument warning, but it'll be
removed automatically on the next bootstrap.
2021-02-03 12:51:39 +01:00
Dmitriy Novozhilov bc3b791cd8 [TMP] Remove :kotlin-coroutines-experimental-compat module 2021-01-28 13:19:34 +03:00
Ilya Gorbunov 8f4e4a4d40 Specify common sources for stdlib test compilation tasks
Some multiplatform tests are compiled in single-platform projects:
- in kotlin-stdlib-jdk7
- in kotlin-stdlib-jdk8
- in kotlin-stdlib-js-ir. The latter is technically MPP but with a
single platform, so its common sources are not considered as common.

Pass information about common sources to test compilation tasks in order
to use OptionalExpectation annotations there.

Co-authored-by: Svyatoslav Scherbina <svyatoslav.scherbina@jetbrains.com>
2020-12-14 19:03:04 +03:00
Ilya Gorbunov 0634351fbc Introduce pathString/absolute/absolutePathString
Rename invariantSeparatorsPath to invariantSeparatorsPathString
to have more consistent names of methods returning path strings.

KT-19192
2020-11-29 17:46:47 +03:00
Ilya Gorbunov 84f5a294f7 Allow passing null parent directory to createTempFile/Directory
null signifies the default temp directory.

KT-19192
2020-11-29 17:46:47 +03:00
Ilya Gorbunov 64d85f259c Relax writeText/appendText parameter type to CharSequence
KT-19192
2020-11-29 17:46:47 +03:00
Ilya Gorbunov 7fd96f5773 Fix annotation spelling in docs
KT-43586
2020-11-26 15:37:22 +03:00
Alexander Udalov d326d6a693 Specify module name via moduleName option instead of freeCompilerArgs
This allows to get rid of warnings about duplicate module name in some
of the modules.
2020-11-06 19:27:32 +01:00
Jake Wharton 3a693e112b Update ExperimentalPathApi annotation's SinceKotlin value to 1.4 2020-10-28 16:55:57 +03:00
Ilya Gorbunov 0fa2cc15de Cleanup more test files and directories after tests
#KT-19192
2020-10-28 07:36:22 +03:00
Ilya Gorbunov fe098ec821 Revise functions in PathReadWrite
- Adjust implementations to avoid excessive vararg copies
- Remove options from forEachLine, it doesn't make much sense and
isn't consistent with the other read* functions.
- Revise inlineness of functions in PathReadWrite
- Compact implementations of those that are remained inline.
- Clarify docs of functions for reading the entire file

#KT-19192
2020-10-28 07:36:19 +03:00
Ilya Gorbunov a43cc0d1f9 Implement additional Path extensions
#KT-19192
2020-10-28 07:36:16 +03:00