thevery
07/16/2018, 2:31 PMAregev2
07/16/2018, 4:16 PMfun main(args: Array<String>) {
println(reflect())
println(::reflect.returnType)
}
fun reflect() = "Reflecting"
napperley
07/17/2018, 12:13 AMnapperley
07/17/2018, 2:18 AMspierce7
07/17/2018, 5:28 AMCGWindowListCopyWindowInfo()
returns an Array of Maps. When I bridge the result with CFBridgingRelease()
, the result is an NSArray of Kotlin maps. Why can't it be a kotlin Array of Kotlin maps? Is there a way for me to manually bridge an NSArray to a Kotlin Array?spierce7
07/17/2018, 5:52 PMthevery
07/17/2018, 9:11 PM"org.jetbrains.kotlinx:kotlinx-coroutines-core-native_release_ios_x64:0.23.4-native-1"
for native coroutines, but I cannot find UI context - is there any available? @elizarovMohit Gurumukhani
07/18/2018, 12:02 AMAregev2
07/19/2018, 8:10 AM.html
file?Aregev2
07/19/2018, 1:11 PMfun main(args: Array<String>) {
val ls = listOf(12, 23, 435).shuffled()
println(ls[0])
}
I have been using this code, and got that output
Uncaught exception from Kotlin's main: kotlin.IndexOutOfBoundsException
at kfun:kotlin.Exception.<init>()kotlin.Exception (0x4068b2)
at kfun:kotlin.RuntimeException.<init>()kotlin.RuntimeException (0x4067e2)
at kfun:kotlin.IndexOutOfBoundsException.<init>()kotlin.IndexOutOfBoundsException (0x406762)
at kfun:kotlin.collections.ArrayList.checkIndex#internal (0x40de44)
at kfun:kotlin.collections.ArrayList.get(<http://kotlin.Int|kotlin.Int>)#GENERIC (0x40feb7)
at kfun:kotlin.collections.shuffle@kotlin.collections.MutableList<#GENERIC>.()Generic (0x41b89f)
at kfun:kotlin.collections.shuffled@kotlin.collections.Iterable<#GENERIC>.()Generic (0x41c109)
at kfun:main(kotlin.Array<kotlin.String>) (0x403e85)
at EntryPointSelector (0x403d06)
at Konan_start (0x403c77)
at Konan_run_start (0x403bf2)
at Konan_main (0x403b67)
at __libc_start_main (0x7f57da6f0b97)
at (0x403a0a)
at ((nil))
Aregev2
07/19/2018, 5:39 PMAregev2
07/19/2018, 6:15 PMbipin
07/19/2018, 7:55 PMD8: Program type already present: com.moviemaker.BuildConfig
> Task :android-app:transformDexArchiveWithDexMergerForDebug FAILED
java.lang.RuntimeException: com.android.builder.dexing.DexArchiveMergerException: Error while merging dex archives:
spierce7
07/19/2018, 9:57 PMspierce7
07/20/2018, 1:28 AMjw
07/20/2018, 2:40 AMbipin
07/20/2018, 3:28 PM> Task :common-ios:compileKonanKotlinMovieMakerIos_x64 FAILED
error: compilation failed: Expected data layout hash: -6046314956093995674 but actual is: 4180466727156567408
alexfacciorusso
07/20/2018, 4:02 PMkotlin-platform-common
plugin), and Android part, and an iOS framework I am building with konan
, that then I load into an iOS app project. There's a problem: It seems that in the konan gradle project I can't import external libraries from gradle (I need the org.jetbrains.kotlinx:jsonparser-native:0.6.0
library, since I'm using kotlinx-serialization-runtime-common
in the shared code). How to do it?thevery
07/21/2018, 2:21 PMAregev2
07/22/2018, 1:02 PMthevery
07/23/2018, 1:11 AMfun search(query: String, model: SearchModel, view: SearchView): Job {
val cancellableJob = launch(CommonPool) {
val data = model.search(query) // (1)
withContext(UI) {
view.showData(data) (2)
}
}
return cancellableJob
}
russhwolf
07/24/2018, 2:26 AMkotlin-platform-native
plugin create objective-c frameworks or is that only supported in konan
for that for now?Aregev2
07/24/2018, 1:33 PMtime.h
header and the cinterop tool throws an exception, can someone help?
time.def
headers = /usr/include/time.h
compilerOpts = -std=c99
Exception in thread "main" java.lang.Error: /usr/include/time.h:37:10: fatal error: 'bits/types/clock_t.h' file not found
at org.jetbrains.kotlin.native.interop.indexer.UtilsKt.ensureNoCompileErrors(Utils.kt:137)
at org.jetbrains.kotlin.native.interop.indexer.IndexerKt.indexDeclarations(Indexer.kt:902)
at org.jetbrains.kotlin.native.interop.indexer.IndexerKt.buildNativeIndexImpl(Indexer.kt:892)
at org.jetbrains.kotlin.native.interop.indexer.NativeIndexKt.buildNativeIndex(NativeIndex.kt:56)
at org.jetbrains.kotlin.native.interop.gen.jvm.MainKt.processCLib(main.kt:284)
at org.jetbrains.kotlin.native.interop.gen.jvm.MainKt.interop(main.kt:38)
at org.jetbrains.kotlin.cli.utilities.InteropCompilerKt.invokeInterop(InteropCompiler.kt:100)
at org.jetbrains.kotlin.cli.utilities.MainKt.main(main.kt:29)
bipin
07/24/2018, 3:25 PMAregev2
07/24/2018, 3:57 PMCPointer<IntVar>
to IntArray
?Dominaezzz
07/25/2018, 11:56 AMMohit Gurumukhani
07/25/2018, 8:36 PMDominaezzz
07/26/2018, 2:44 PMspierce7
07/26/2018, 9:59 PMspierce7
07/26/2018, 10:00 PM