Simon Nozaki
06/14/2022, 8:42 AMgood-first-issue
on YouTrack or other way?
It seems that Kotlin YouTrack has no issues or tags of it.
Thanks.Phani Mahesh
06/14/2022, 12:49 PMcheeze2000
06/14/2022, 12:53 PMhello.kt
file and then the error Could not find 'main' in '<root>' package.
happens. does anyone know how i can update the gradle file so it builds successfully again?cheeze2000
06/14/2022, 11:55 PMbuild.gradle.kts
kotlin {
linuxX64("native") {
binaries {
executable()
}
}
mingwX64("native") {
binaries {
executable()
}
}
}
is this the correct way to define multiple targets? if so, how do i run gradle to compile for both platforms? there is an error when i run gradle nativeBinaries
: The target 'native' already exists, but it was not created with the 'mingwX64' preset. To configure it, access it by name in kotlin.targets
or use the preset function 'linuxX64'.elect
06/15/2022, 10:57 AMfun TfFile.cert_request(configure: CertRequest.() -> Unit): CertRequest
fun TfFile.cert_request(configure: CertRequest.() -> Unit): PropertyDelegateProvider<Any?, ReadOnlyProperty<Any?, CertRequest>>
@JvmName
works only for case like List<String
and List<Int
and @OverloadResolutionByLambdaReturnType
only with lambdas returning different valuesStarr
06/15/2022, 11:00 AMdeviant
06/15/2022, 12:23 PMNorbi
06/15/2022, 8:24 PMki-shell 0.4.6-SNAPSHOT/1.6.21
type :h for help
[0] :dependsOn <my library here>
[1] some.package.test()
ERROR Class 'some.package.TestKt' is compiled by a pre-release version of Kotlin and cannot be loaded by this version of the compiler (Line_2.kts:1:15)
I even tried to compile a custom version of ki-shell with Kotlin 1.6.21 but nothing changed.
My project is also compiled using Kotlin 1.6.21.
May I ask what triggers the "pre-release" property of a compiled class?
Thanks.Dieter Konrad
06/16/2022, 1:24 PMSid Med
06/16/2022, 11:06 PMSid Med
06/16/2022, 11:06 PMSid Med
06/16/2022, 11:06 PMzain
06/17/2022, 7:54 AMval employees =
listOf<Employee>(
Employee(
id = 1,
listOf(
Address(id = 1, isPerm = false),
Address(id = 2, isPerm = true),
Address(id = 3, isPerm = true)
)
),
Employee(
id = 2,
listOf(
Address(id = 1, isPerm = false),
Address(id = 2, isPerm = false),
Address(id = 3, isPerm = true)
)
)
)
server
06/17/2022, 1:20 PMVampire
06/17/2022, 3:24 PMLawrence
06/18/2022, 2:48 PMmoltendorf
06/18/2022, 9:41 PMuseLocation() may be used only in the context of a <Router> component
no matter which block I put it in?
val App = FC<Props> {
BrowserRouter {
Routes {
Route {
useLocation() // ...
cheeze2000
06/19/2022, 9:51 AMYoussef Shoaib [MOD]
06/19/2022, 2:22 PMlist1.zip(list2).toMap()
but it turns them into pairs in the process and I don't quite like that. Is there a neater 1-liner for it? I looked at associateWtih and associateBy but I can't seem to get them to work for this use case.
Edit: Neatest one-liner I've found: (0..list1.lastIndex).associateBy(list1::get, list2::get)
Hassaan
06/19/2022, 7:15 PMandylamax
06/19/2022, 10:48 PMclass Zipped<out T>(val value:T)
// function one
fun <T,R> Zipped<T>.map(mapper: (T)->R): Zipped<R> {
// . . .
}
// function two
fun <T,R> Zipped<Zipped<T>>.map(mapper: (T)->R) : Zipped<R> {
// . . .
}
fun main() {
val zipped: Zipped<Zipped<Int>> = Zipped(Zipped(2))
val result = zipped.map { "zipped value: $it" } // when calling this function?
}
jeggy
06/20/2022, 8:00 AMInt
and not a Long
?Vitali Plagov
06/20/2022, 7:22 PM"aaa\"aaa"
. When I evaluate an expression while in debug and check the length of the string, then it shows it is 8.
But checking the same in the scratch file - it shows length equal to 7. Why is it so? What am I missing?Michael de Kaste
06/21/2022, 1:15 PMPhani Mahesh
06/21/2022, 3:23 PMNga Pham
06/21/2022, 3:23 PMcheeze2000
06/21/2022, 4:40 PM./gradlew build
and ./gradlew run
. is it possible to specify --console=plain
inside the build.gradle.kts
file on one of them so i don't have to keep typing the flag?Wolfgang
06/21/2022, 4:57 PMMatthew Murray
06/21/2022, 6:57 PMMatthew Murray
06/21/2022, 6:58 PMswitch
statement from Kotlin/Native in Obj-C, since it converts Kotlin enums to a class, not an actual enum.