*a38651c1ec- (tag: build-1.3.60-dev-1448) KT-32366: Add missing 182 bunch file for the `foldingTestUtils.kt` (3 days ago) <Roman Golyshev> *5a511dd635- (tag: build-1.3.60-dev-1446) Refactor and fix of the run/apply/let/also intention converter (3 days ago) <Igor Yakovlev> *ef5fcb4e9e- (tag: build-1.3.60-dev-1439) Fix test data (3 days ago) <Ilmir Usmanov> *37e3c41b57- (tag: build-1.3.60-dev-1434) KT-32366: Add sync scroll for source and preview editor (3 days ago) <Roman Golyshev> *e488e920d8- KT-32366: Add tests for right preview window (3 days ago) <Roman Golyshev> *bddf87337c- KT-32366: Add printing scratch output to preview window (3 days ago) <Roman Golyshev> *e321ee1396- KT-32366: Inject `toolWindowHandler` from `InlayScratchOutputHandler` (3 days ago) <Roman Golyshev> *d0cd4967a7- KT-32366: Extract text styling variables to `outputStylingUtils` (3 days ago) <Roman Golyshev> *358ec2b8bd- KT-32366: Refactor tests to allow testing of preview window (3 days ago) <Roman Golyshev> *dd1ace37d2- KT-32366: Add `TextEditorWithPreview.setLayout` method (3 days ago) <Roman Golyshev> *1d6de45db6- KT-32366: Use `TextEditorWithPreview` as editor for scratch files (3 days ago) <Roman Golyshev> *37c6102a03- KT-32366: Change base of `AbstractScratchLineMarkersTest` (3 days ago) <Roman Golyshev> *1177566386- KT-32366: Get rid of `ScratchTopPanel` in tests (3 days ago) <Roman Golyshev> *962260941b- KT-32366: Add `TextEditorWithPreview` class from the platform (3 days ago) <Roman Golyshev> *54dde777ac- KT-32366: Get replace editor with virtual file in `ScratchFile` (3 days ago) <Roman Golyshev> *1fc88fc47f- KT-32366: Refactor `ScratchPanelListener` to `ScratchFileListener` (3 days ago) <Roman Golyshev> *ea3d070c98- KT-32366: Refactor `ScratchFileHook` to make ScratchFile creation clear (3 days ago) <Roman Golyshev> *70e6f738eb- KT-32366: Refactor `scratchUtils` to use mostly `ScratchFile` (3 days ago) <Roman Golyshev> *6c35c40bb9- KT-32366: Refactor `ScratchTopPanel` to actions instead of custom UI (3 days ago) <Roman Golyshev> *23f662cfe2- (tag: build-1.3.60-dev-1429) FIR: optimize creation of scope by implicit receiver (3 days ago) <Mikhail Glukhikh> *9c3821ddba- FIR: add comments & tests for tower resolver, block some receiver pairs (3 days ago) <Mikhail Glukhikh> *c9a600c5ce- FIR: handle imported members from objects more correctly (3 days ago) <Mikhail Glukhikh> *a4d89b9829- FIR: handle situations with multiple implicit receivers (3 days ago) <Mikhail Glukhikh> *5d6a526eec- FIR: more accurate handling of dispatch receiver values (3 days ago) <Mikhail Glukhikh> *fcb0b1b5eb- (tag: build-1.3.60-dev-1427) Add new native targets. (#2538) (3 days ago) <Nikolay Igotti> *64d4cca589- (tag: build-1.3.60-dev-1419) Redundant override: do not report when class has derived property (3 days ago) <Toshiaki Kameyama> *729ed1a44e- (tag: build-1.3.60-dev-1417) Pull Members Up: fix invalid code format on function with comment and another indent (3 days ago) <Toshiaki Kameyama> *7c2f6ecba7- (tag: build-1.3.60-dev-1416) Redundant curly braces in string template: remove braces for 'this' (3 days ago) <Toshiaki Kameyama> *8f2a73b734- (tag: build-1.3.60-dev-1415) KT-28471: "Add initializer" quickfix initializes non-null variable with null (3 days ago) <Dereck Bridie> *c0f896c96a- flatMap call could be simplified to flatten(): Fix false positive with Array (3 days ago) <Toshiaki Kameyama> *7ff01b02a9- (tag: build-1.3.60-dev-1411) Make ExperimentalTime annotation documented (4 days ago) <Ilya Gorbunov> *2c79b1f89e- Minor: fix incorrect reference in kdoc (4 days ago) <Ilya Gorbunov> *daa0d58f4d- (tag: build-1.3.60-dev-1410) Build: Update list of proxied repositories (4 days ago) <Vyacheslav Gerasimov> *1cdc68901a- Build: Use kotlinx-metadata-jvm from jcenter instead of bintray (4 days ago) <Vyacheslav Gerasimov> *96c9efeabb- Build: Fix findNonCachedRepositories test (4 days ago) <Vyacheslav Gerasimov> *669b6d164c- Build: Use cache redirector for buildscript block of :kotlin-reflect (4 days ago) <Vyacheslav Gerasimov> *d59f2bcc80- (tag: build-1.3.60-dev-1404) Fix KotlinReflectionInternalError on invoking callBy with defaults in supertypes (4 days ago) <Alexander Udalov> *cb2e68fece- JVM IR: skip temporary variables in InventNamesForLocalClasses (4 days ago) <Alexander Udalov> *312205f376- Prohibit synchronized methods on interface members (4 days ago) <Alexander Udalov> *815ff3c860- JVM IR: don't generate ACC_FINAL on DefaultImpls methods (4 days ago) <Alexander Udalov> *6f785ec881- (tag: build-1.3.60-dev-1401) FIR2IR: fix library annotation call generation (4 days ago) <Mikhail Glukhikh> *27ccff12c1- FIR: add resolve for delegated super-type (4 days ago) <Mikhail Glukhikh> *a9bc3c19d6- (tag: build-1.3.60-dev-1393) Fix invalid generated Move tests (4 days ago) <Igor Yakovlev> *f9506db20a- (tag: build-1.3.60-dev-1390) Ignore sources which are not LOADs in refinedIntTypeAnalysis (4 days ago) <Ilmir Usmanov> *4697822b5a- (tag: build-1.3.60-dev-1389) [FIR] Fix setting return type for `when` and `try` with non applicable candidates (4 days ago) <Dmitriy Novozhilov> *6e6ffa12a6- [WASM] Initial infrastructure (4 days ago) <Svyatoslav Kuzmich> *812083ee05- [WASM] Initial runtime library (4 days ago) <Svyatoslav Kuzmich> *1891fa1bf1- [JS IR BE] Commonize JS lowerings (4 days ago) <Svyatoslav Kuzmich> *7bc739359b- (tag: build-1.3.60-dev-1387) Use JDK_8 when stopping Gradle daemons with version below 5.0 (4 days ago) <Ivan Gavrilovic> *d13e26d67e- Add a check that processors from KAPT classpath are not run (4 days ago) <Ivan Gavrilovic> *27a9aa5e2b- KT-33056: Fix how parent class loader for KAPT processors is found (4 days ago) <Ivan Gavrilovic> *f3acd8d10c- KT-33028, KT-33050: Fix how kapt invokes javac on JDK 9+ (4 days ago) <Ivan Gavrilovic> *5846db4eab- (tag: build-1.3.60-dev-1379) [FIR] Add symbol to FirFunction and all it's inheritors (4 days ago) <Dmitriy Novozhilov> *e3e1f3c2aa- [FIR] Fix transforming value parameters of anonymous functions (4 days ago) <Dmitriy Novozhilov> *d841090866- [FIR] Don't analyze properties with implicit types twice (4 days ago) <Dmitriy Novozhilov> *f1e56c4b3e- [FIR] Force resolving all declaration while resolving of body with implicit type (4 days ago) <Dmitriy Novozhilov> *e374242adf- [FIR] Fix propagating expected type for binary operator calls (4 days ago) <Dmitriy Novozhilov> *ba7a137e74- [FIR] Add fir node for binary && and || (4 days ago) <Dmitriy Novozhilov> *908b6ade1d- [FIR] Fix incorrect do-while loop transforming order and IR generating (4 days ago) <Dmitriy Novozhilov> *42f171a8d2- [IR] Minor. Extract irBuiltins from IrGeneratorContext to separate interface (4 days ago) <Dmitriy Novozhilov> *b274c7567e- [FIR] Minor. Add `transformResult` to `FirWhenBranch` (4 days ago) <Dmitriy Novozhilov> *a022f85776- [FIR] Minor. Add `@BaseTransformedType` to `FirWhenBranch` (4 days ago) <Dmitriy Novozhilov> *f877fe40b3- [FIR] Fix expected type in invoke completion (4 days ago) <Dmitriy Novozhilov> *57a2665b00- [FIR] Update tests for previous commit (4 days ago) <Dmitriy Novozhilov> *e48959350c- [FIR] Infer type of when expressions and try expressions like it is function call (4 days ago) <Dmitriy Novozhilov> *741ff958e8- [FIR] Add util function for extracting return arguments from block (4 days ago) <Dmitriy Novozhilov> *fe3824d796- [FIR] Introduce `FirResolvable` (4 days ago) <Dmitriy Novozhilov> *beeba23cf0- [FIR] Minor. Wrap `withScopeCleanup` with try-finally (4 days ago) <Dmitriy Novozhilov> *e944119f71- [FIR] Don't use implicit type as expected type of anonymous function (4 days ago) <Dmitriy Novozhilov> *7861396246- [FIR] Add util function for creating functional cone type (4 days ago) <Dmitriy Novozhilov> *637fb55a7b- [FIR] Add implementation of intersection types to Fir type system (4 days ago) <Dmitriy Novozhilov> *1708a34eb8- [FIR] Fix incorrect findCommonIntegerLiteralTypesSuperType dummy implementation (4 days ago) <Dmitriy Novozhilov> *e6bf3b3263- [FIR] Render nullability in type renderer, not in fir renderer (4 days ago) <Dmitriy Novozhilov> *3e44bc805f- [FIR] Return error type from common super type if it present (4 days ago) <Dmitriy Novozhilov> *6e2958880b- [FIR] Add forgotten replacing arguments in abbreviated type expansion (4 days ago) <Dmitriy Novozhilov> *317e3edba8- [FIR] Add default upper bound to type parameter in fir deserializer (4 days ago) <Dmitriy Novozhilov> *2fe01f9086- (tag: build-1.3.60-dev-1358) Refactor publishing plugin to lazy tasks API (5 days ago) <Ilya Chernikov> *315a9d66a0- Refactor more tasks to lazy API (5 days ago) <Ilya Chernikov> *2ed8fa7624- Convert main task creating helper to lazy API, refactor accordingly (5 days ago) <Ilya Chernikov> *0f41dc814f- Switch many common tasks defined in buildSrc to lazy creation (5 days ago) <Ilya Chernikov> *f74c4fa538- Switch all common tasks in the root build script to lazy creation (5 days ago) <Ilya Chernikov> *5208318f34- Fix dependency resolution during gradle project configuration (5 days ago) <Ilya Chernikov> *50e758cbb7- (tag: build-1.3.60-dev-1355) Remove the `@Inclubating` annotation from UnstableApiUsage inspection (5 days ago) <Sergey Igushkin> *ffd0b438da- Don't create the Kapt generate stubs output dir in lazy initializer (5 days ago) <Sergey Igushkin> *cbb8bf2deb- Extract members from Kotlin tasks, don't iterate over them (KT-31713) (5 days ago) <Sergey Igushkin> *80fa591f10- (tag: build-1.3.60-dev-1345) Fix failing test because of slightly different diagnostics for LV=1.2 (5 days ago) <Mikhail Zarechenskiy> *5e3a11db8e- (tag: build-1.3.60-dev-1327, origin/rr/4u7/publishing-fixes-before) JVM IR: remove property accessor name hack in InterfaceDelegationLowering (5 days ago) <Alexander Udalov> *14a6a06166- JVM IR: do not use GenerationState.typeMapper (5 days ago) <Alexander Udalov> *f64afbf152- JVM IR: reduce usages of IrTypeMapper.kotlinTypeMapper (5 days ago) <Alexander Udalov> *0c6ab69b52- JVM IR: do not use descriptors in IrTypeMapper.writeFormalTypeParameters (5 days ago) <Alexander Udalov> *598c6009f2- JVM IR: extract method signature mapping to MethodSignatureMapper (5 days ago) <Alexander Udalov> *6191fc10f0- JVM IR: introduce IrCallableMethod as a simpler replacement for CallableMethod (5 days ago) <Alexander Udalov> *6969717201- (tag: build-1.3.60-dev-1315) Fix performanceTests compilation errors (5 days ago) <Vladimir Dolzhenko> *d1cbee44f1- (tag: build-1.3.60-dev-1309, origin/spec-tests) Move refactoring: suggest file name starting with an uppercase letter (6 days ago) <Burak Eregar> *8219d9853c- (tag: build-1.3.60-dev-1304) Implement configuration for describing only published runtime dependencies... (6 days ago) <Ilya Chernikov> *3d3e86b5fa- (tag: build-1.3.60-dev-1290) Added gradle.kts and annotator gradle.kts autocompletion performance benchmark (6 days ago) <Vladimir Dolzhenko> *7c4ed9c29e- (tag: build-1.3.60-dev-1286) JVM IR: remove unused code, minor cleanup (6 days ago) <Alexander Udalov> *23e79bb32b- (tag: build-1.3.60-dev-1275) ScriptDefinitionsManager: `safeGetDefinitions` shouldn't catch `ControlFlowException` #EA-210332 Fixed (6 days ago) <Dmitry Gridin> *ef4bac1b46- REPL: fix `IllegalArgumentException` Reproduce: select `Pause Output` #EA-209571 Fixed #EA-210364 Fixed #KT-33329 Fixed (6 days ago) <Dmitry Gridin> *f81fb40164- HistoryUpdater: cleanup code (6 days ago) <Dmitry Gridin> *df438377e8- ReplOutputProcessor: cleanup code (6 days ago) <Dmitry Gridin> *ab4001a698- KotlinCopyPasteReferenceProcessor: fix KNPE #EA-210304 Fixed (6 days ago) <Dmitry Gridin> *693f42f33e- KotlinCopyPasteReferenceProcessor: cleanup code (6 days ago) <Dmitry Gridin> *bd5476082b- extractionModel: cleanup code (6 days ago) <Dmitry Gridin> *fcff9a43b4- extractionModel: fix NPE #EA-210243 Fixed (6 days ago) <Dmitry Gridin> *f87e86d4b3- CallableBuilder: fix exception #EA-134361 Fixed (6 days ago) <Dmitry Gridin> *76b97c3847- CallableBuilder: cleanup code (6 days ago) <Dmitry Gridin> *2b90735990- generateUtil: fix PIEAE #EA-209598 Fixed #EA-142347 Fixed (6 days ago) <Dmitry Gridin> *b570f99aae- generateUtil: cleanup code (6 days ago) <Dmitry Gridin> *cf3b92d80e- CreateTypeParameterFromUsageFix: fix KNPE for type alias #KT-33302 Fixed #EA-120181 Fixed (6 days ago) <Dmitry Gridin> *932765744a- CreateTypeParameterFromUsageFix: cleanup code (6 days ago) <Dmitry Gridin> *8d2ccb7bcd- (tag: build-1.3.60-dev-1268) [IR] Taught inliner to work with inline suspend lambdas (6 days ago) <Igor Chevdar> *7ff700ff97- (tag: build-1.3.60-dev-1260) JVM_IR: lower calls to @JvmStatic functions from other files. (6 days ago) <pyos> *24adc09e2d- (tag: build-1.3.60-dev-1256) J2K: Change old/new J2K switch checkbox text from "Use New J2K" to "Use New Java to Kotlin Converter" (6 days ago) <Ilya Kirillov> *ad43bc23ea- (tag: build-1.3.60-dev-1244) Minor, add test case on SAM conversion over smart cast (7 days ago) <Alexander Udalov> *dd0e296af1- (tag: build-1.3.60-dev-1241) Use KotlinExceptionWithAttachments for ToFromOriginalFileMapper and MainFunctionDetector (7 days ago) <Vladimir Dolzhenko> *fa29297fb1- (tag: build-1.3.60-dev-1235) Introduce workaround for back-end exception in the test cases parser code (7 days ago) <victor.petukhov> *9487d291da- Fail spec box tests if they have `unexpected behaviour` and passed (7 days ago) <victor.petukhov> *d8e5b068d5- Relinking spec tests (7 days ago) <victor.petukhov> *8465d690f1- Add spec tests for 'Type system' (introduction and 'kotlin.Any' type) (7 days ago) <victor.petukhov> *f78faeaa3c- Add test for consistency check between the Kotlin specification and spec tests (7 days ago) <victor.petukhov> *4f73e100d0- Add task to generate tests json map (is used for tool 'spec-tests-relinking recommender') (7 days ago) <victor.petukhov> *0e439263ce- Group spec tests and accompanying functionality into to packages: org.jetbrains.kotlin.spec (tests only) and org.jetbrains.kotlin.spec.utils (accompanying functionality) (7 days ago) <victor.petukhov> *cf692fb257- Implement tests map generator and refactor folder structure to spec tests linking (7 days ago) <victor.petukhov> *28da325a11- Actualize DFA spec tests (7 days ago) <victor.petukhov> *c43df55965- (tag: build-1.3.60-dev-1228) Type parameters are placed before the name of the function (7 days ago) <SatoShun> *9c861a111f- Fix move refactoring conflict window output (7 days ago) <Igor Yakovlev> *ae3f36ebde- Change ExtractDeclarationFromCurrentFileIntention applicability range (7 days ago) <Igor Yakovlev>
Kotlin/Native
Kotlin/Native is an LLVM backend for the Kotlin compiler, runtime implementation, and native code generation facility using the LLVM toolchain.
Kotlin/Native is primarily designed to allow compilation for platforms where virtual machines are not desirable or possible (such as iOS or embedded targets), or where a developer is willing to produce a reasonably-sized self-contained program without the need to ship an additional execution runtime.
Prerequisites:
- install JDK for your platform, instead of JRE. The build requires
tools.jar, which is not included in JRE; - on macOS install Xcode 10.2
- on Fedora 26+
yum install ncurses-compat-libsmay be needed - on recent Ubuntu
apt install libncurses5is needed
To compile from sources use following steps:
First, download dependencies:
./gradlew dependencies:update
Then, build the compiler and libraries:
./gradlew bundle
To build with experimental targets support compile with -Porg.jetbrains.kotlin.native.experimentalTargets.
The build can take about an hour on a Macbook Pro. To run a shorter build with only the host compiler and libraries, run:
./gradlew dist distPlatformLibs
To include Kotlin compiler in composite build and build
against it, use the kotlinProjectPath project property:
./gradlew dist -PkotlinProjectPath=path/to/kotlin/project
To include Kotlin/Native Shared in a composite build and build against
it, use the sharedProjectPath project property:
./gradlew dist -PsharedProjectPath=path/to/kotlin/native/shared
It's possible to include in a composite build both Kotlin compiler and Kotlin/Native Shared simultaneously.
After that, you should be able to compile your programs like this:
export PATH=./dist/bin:$PATH
kotlinc hello.kt -o hello
For an optimized compilation, use -opt:
kotlinc hello.kt -o hello -opt
For tests, use:
./gradlew backend.native:tests:run
To generate interoperability stubs, create a library definition file
(refer to samples/tetris/.../sdl.def), and run the cinterop tool like this:
cinterop -def lib.def
See the provided samples and INTEROP.md for more details.
The Interop tool generates a library in the .klib library format. See LIBRARIES.md
for more details on this file format.