https://kotlinlang.org logo
Join the conversationJoin Slack
Channels
100daysofcode
100daysofkotlin
100daysofkotlin-2021
advent-of-code
aem
ai
alexa
algeria
algolialibraries
amsterdam
android
android-architecture
android-databinding
android-studio
androidgithubprojects
androidthings
androidx
androidx-xprocessing
anime
anko
announcements
apollo-kotlin
appintro
arabic
argentina
arkenv
arksemdevteam
armenia
arrow
arrow-contributors
arrow-meta
ass
atlanta
atm17
atrium
austin
australia
austria
awesome-kotlin
ballast
bangladesh
barcelona
bayarea
bazel
beepiz-libraries
belgium
berlin
big-data
books
boston
brazil
brikk
budapest
build
build-tools
bulgaria
bydgoszcz
cambodia
canada
carrat
carrat-dev
carrat-feed
chicago
chile
china
chucker
cincinnati-user-group
cli
clikt
cloudfoundry
cn
cobalt
code-coverage
codeforces
codemash-precompiler
codereview
codingame
codingconventions
coimbatore
collaborations
colombia
colorado
communities
competitive-programming
competitivecoding
compiler
compose
compose-android
compose-desktop
compose-hiring
compose-ios
compose-mp
compose-ui-showcase
compose-wear
compose-web
connect-audit-events
corda
cork
coroutines
couchbase
coursera
croatia
cryptography
cscenter-course-2016
cucumber-bdd
cyprus
czech
dagger
data2viz
databinding
datascience
dckotlin
debugging
decompose
decouple
denmark
deprecated
detekt
detekt-hint
dev-core
dfw
docs-revamped
dokka
domain-driven-design
doodle
dsl
dublin
dutch
eap
eclipse
ecuador
edinburgh
education
effective-kotlin
effectivekotlin
emacs
embedded-kotlin
estatik
event21-community-content
events
exposed
failgood
fb-internal-demo
feed
firebase
flow
fluid-libraries
forkhandles
forum
fosdem
fp-in-kotlin
framework-elide
freenode
french
fritz2
fuchsia
functional
funktionale
gamedev
ge-kotlin
general-advice
georgia
geospatial
german-lang
getting-started
github-workflows-kt
glance
godot-kotlin
google-io
gradle
graphic
graphkool
graphql
graphql-kotlin
graviton-browser
greece
grpc
gsoc
gui
hackathons
hacktoberfest
hamburg
hamkrest
helios
helsinki
hexagon
hibernate
hikari-cp
hire-me
hiring
hongkong
hoplite
http4k
hungary
hyderabad
image-processing
india
indonesia
inkremental
intellij
intellij-plugins
intellij-tricks
internships
introduce-yourself
io
ios
iran
israel
istanbulcoders
italian
jackson-kotlin
jadx
japanese
jasync-sql
java-to-kotlin-refactoring
javadevelopers
javafx
javalin
javascript
jdbi
jhipster-kotlin
jobsworldwide
jpa
jshdq
juul-libraries
jvm-ir-backend-feedback
jxadapter
k2-early-adopters
kaal
kafka
kakao
kalasim
kapt
karachi
karg
karlsruhe
kash_shell
kaskade
kbuild
kdbc
kgen-doc-tools
kgraphql
kinta
klaxon
klock
kloudformation
kmdc
kmm-español
kmongo
knbt
knote
koalaql
koans
kobalt
kobweb
kodein
kodex
kohesive
koin
koin-dev
komapper
kondor-json
kong
kontent
kontributors
korau
korean
korge
korim
korio
korlibs
korte
kotest
kotest-contributors
kotless
kotlick
kotlin-asia
kotlin-beam
kotlin-by-example
kotlin-csv
kotlin-data-storage
kotlin-foundation
kotlin-fuel
kotlin-in-action
kotlin-inject
kotlin-latam
kotlin-logging
kotlin-multiplatform-contest
kotlin-mumbai
kotlin-native
kotlin-pakistan
kotlin-plugin
kotlin-pune
kotlin-roadmap
kotlin-samples
kotlin-sap
kotlin-serbia
kotlin-spark
kotlin-szeged
kotlin-website
kotlinacademy
kotlinbot
kotlinconf
kotlindl
kotlinforbeginners
kotlingforbeginners
kotlinlondon
kotlinmad
kotlinprogrammers
kotlinsu
kotlintest
kotlintest-devs
kotlintlv
kotlinultimatechallenge
kotlinx-datetime
kotlinx-files
kotlinx-html
kotrix
kotson
kovenant
kprompt
kraph
krawler
kroto-plus
ksp
ktcc
ktfmt
ktlint
ktor
ktp
kubed
kug-leads
kug-torino
kvision
kweb
lambdaworld_cadiz
lanark
language-evolution
language-proposals
latvia
leakcanary
leedskotlinusergroup
lets-have-fun
libgdx
libkgd
library-development
linkeddata
lithuania
london
losangeles
lottie
love
lychee
macedonia
machinelearningbawas
madrid
malaysia
mathematics
meetkotlin
memes
meta
metro-detroit
mexico
miami
micronaut
minnesota
minutest
mirror
mockk
moko
moldova
monsterpuzzle
montreal
moonbean
morocco
motionlayout
mpapt
mu
multiplatform
mumbai
munich
mvikotlin
mvrx
myndocs-oauth2-server
naming
navigation-architecture-component
nepal
new-mexico
new-zealand
newname
nigeria
nodejs
norway
npm-publish
nyc
oceania
ohio-kotlin-users
oldenburg
oolong
opensource
orbit-mvi
osgi
otpisani
package-search
pakistan
panamá
pattern-matching
pbandk
pdx
peru
philippines
phoenix
pinoy
pocketgitclient
polish
popkorn
portugal
practical-functional-programming
proguard
prozis-android-backup
pyhsikal
python
python-contributors
quasar
random
re
react
reaktive
realm
realworldkotlin
reductor
reduks
redux
redux-kotlin
refactoring-to-kotlin
reflect
refreshversions
reports
result
rethink
revolver
rhein-main
rocksdb
romania
room
rpi-pico
rsocket
russian
russian_feed
russian-kotlinasfirst
rx
rxjava
san-diego
science
scotland
scrcast
scrimage
script
scripting
seattle
serialization
server
sg-user-group
singapore
skia-wasm-interop-temp
skrape-it
slovak
snake
sofl-user-group
southafrica
spacemacs
spain
spanish
speaking
spek
spin
splitties
spotify-mobius
spring
spring-security
squarelibraries
stackoverflow
stacks
stayhungrystayfoolish
stdlib
stlouis
strife-discord-lib
strikt
students
stuttgart
sudan
swagger-gradle-codegen
swarm
sweden
swing
swiss-user-group
switzerland
talking-kotlin
tallinn
tampa
teamcity
tegal
tempe
tensorflow
terminal
test
testing
testtestest
texas
tgbotapi
thailand
tornadofx
touchlab-tools
training
tricity-kotlin-user-group
trójmiasto
truth
tunisia
turkey
turkiye
twitter-feed
uae
udacityindia
uk
ukrainian
uniflow
unkonf
uruguay
utah
uuid
vancouver
vankotlin
vertx
videos
vienna
vietnam
vim
vkug
vuejs
web-mpp
webassembly
webrtc
wimix_sentry
wwdc
zircon
Powered by Linen
announcements
  • e

    elect

    10/14/2018, 6:50 PM
    I just updated to
    1.3.0-rc-152
    and now I get
    Could not find org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.0-rc-152.
    .. anybody else?
    s
    h
    • 3
    • 17
  • n

    Nikky

    10/14/2018, 6:54 PM
    feels like i saw this question often enough that i should write a tutorial about how to use pluginManagement with kotlin eap or someone who already got medium and would not mind writing some fancy words around the basic gradle code ? not like its complicated, it just feels like most people do not even know that you can instruct gradle how to resolve plgins
    h
    • 2
    • 2
  • b

    bkenn

    10/14/2018, 9:15 PM
    How often are RCs pushed to bintray https://dl.bintray.com/kotlin/kotlin-eap? I see on github the most recent version of kotlin is 1.3.0-rc-168 but on bintrray, the highest RC is 1.3.0-rc-146.
    c
    i
    • 3
    • 3
  • i

    itnoles

    10/15/2018, 2:35 AM
    I have a question about Kotlin 1.3 coroutines. When I took on one of suspend function that return String by ByteCode Viewer, I noticed <undefined type>
    r
    n
    • 3
    • 6
  • t

    toxara

    10/15/2018, 7:34 AM
    Is there any way to make a function such as
    handleBox
    typecheck without unsafe casting?
    Box.kt
    l
    k
    a
    • 4
    • 11
  • s

    Sudhir Singh Khanger

    10/15/2018, 11:05 AM
    Are there branding guidelines for Kotlin programming language? I would like to see
    kt
    files with Kotlin icon and not as a standard text file icon in Linux/KDE.
    k
    • 2
    • 2
  • h

    Hamza

    10/15/2018, 2:28 PM
    When you create a java class (with IDEA), and provide the name
    com.ab.cd.ef
    .) it creates the package
    <http://com.ab.cd|com.ab.cd>
    and puts the class
    ef
    inside it. Doing the same with Kotlin, it creates a file called
    com.ab.cd.ef
    . Whyyyy 😞
    ➕ 1
    t
    h
    • 3
    • 10
  • n

    natpryce

    10/15/2018, 3:41 PM
    Hi. I’m using a third-party Kotlin library compiled for JVM 1.6. My application is targeting JVM 1.8. When I try to compile my code that calls an inline higher-order function in the library, I get the following compilation error:
    Error:(17, 5) Kotlin: Cannot inline bytecode built with JVM target 1.8 into bytecode that is being built with JVM target 1.6. Please specify proper '-jvm-target' option
    What’s the solution to this?
    c
    c
    g
    • 4
    • 18
  • o

    orangy

    10/15/2018, 8:10 PM
    📣 I’ve created #webassembly for topics specific to this platform.
    ➕ 2
    ✔️ 1
    n
    • 2
    • 3
  • o

    otakusenpai

    10/16/2018, 1:51 AM
    So I hav a List<String> of values like "net" and "com". And I have a function where I have to iterate over this list and return a boolean whenever the value of the list matches a string. How do I do this? perhaps onEach can help, but idk how to implement that.
    g
    h
    s
    • 4
    • 4
  • d

    Davio

    10/16/2018, 5:44 AM
    I saw the list, but didn't find the reasoning to leave them out, whether it was a concious design decision or just something they hadn't come around to
    m
    s
    k
    • 4
    • 3
  • s

    spand

    10/16/2018, 8:51 AM
    Is there some easy way to list the public members (classes, funs, vals) of a kotlin module ?
    g
    n
    • 3
    • 14
  • a

    arekolek

    10/16/2018, 9:27 AM
    I wanted to see how a function similar to this
    fromJson
    function behaves with a generic type and found this. Can anybody explain why that instance check is sometimes true and other times false? 🤔
    :youtrack: 1
    g
    h
    +3
    • 6
    • 53
  • h

    Hamza

    10/16/2018, 9:41 AM
    Who here has actually used === on their code? Why did you use it? I personally have never needed to
    n
    r
    +3
    • 6
    • 9
  • j

    Jakub

    10/16/2018, 10:04 AM
    It works, but
    Void
    ? Is there something more Kotlinish? Or this is because I’m using
    RxJava
    not
    RxKotlin
    k
    • 2
    • 1
  • o

    otakusenpai

    10/16/2018, 10:37 AM
    fun foo(foo1: String) : Boolean {
            var hasit = false
            for(fooS in fooList) {
                if(fooS == foo1) {
                    hasit = true
                    break
                }
                else continue
            }
            return hasit
        }
    ...
    var fooList = listOf<String>(...)
    How do i change the above function to use collection functions like forEach or anything else ?
    r
    • 2
    • 1
  • a

    arekolek

    10/16/2018, 10:37 AM
    fooList.any { foo1 == it }
    ?
    👍 3
    o
    • 2
    • 2
  • r

    robstoll

    10/16/2018, 10:43 AM
    Will inline classes allow to wrap a pair? would be nice to have named pairs without overhead
    a
    b
    +2
    • 5
    • 11
  • n

    Nikky

    10/16/2018, 12:05 PM
    you can clear the gradle cache if you want
    m
    • 2
    • 1
  • g

    GarouDan

    10/16/2018, 12:40 PM
    if we have a base class with a property like:
    var parent: MyAbstractClass? = null
    how can I override this property in some of the concrete class to have something like:
    override var parent: MyConcreteClass? = null
    I know that is possible to override properties, but it looks like kotlin do not understand that the MyConcreteClass is a supertype coming from the MyAbstractClass. Is there a way to get around this?
    🎉 1
    i
    a
    • 3
    • 12
  • u

    user

    10/16/2018, 12:56 PM
    message has been deleted
    🍻 5
    🎉 13
    o
    t
    • 2
    • 3
  • f

    frellan

    10/16/2018, 2:08 PM
    If I have a collection and i want to chain
    .filter
    only if a certain condition is true, how do I do that?
    .apply { if (boolean) filter {} }
    does not seem to work
    g
    s
    • 3
    • 7
  • s

    Slackbot

    10/16/2018, 2:09 PM
    This message was deleted.
    a
    b
    e
    • 4
    • 3
  • r

    Ruckus

    10/16/2018, 6:30 PM
    So much for staving off that discussion 🙂
    😂 2
    a
    p
    • 3
    • 2
  • u

    ulrikguenther

    10/16/2018, 7:54 PM
    is there actually a timeline/roadmap for the 1.3 release?
    ❓ 2
    l
    a
    • 3
    • 4
  • d

    DALDEI

    10/16/2018, 8:42 PM
    public interface JavaDup
    {
     // public String a ;
      public String getA();//{ return a ; }
      public void setA(String a) ;//{ a=_a;}
    }
    ----- kotlin
    import util.JavaDup
    
    class B : JavaDup {
      override var a : String = "hi"
    }
    k
    h
    • 3
    • 3
  • d

    Davio

    10/17/2018, 4:41 AM
    Is there a good way to get code coverage for Kotlin with something like JaCoCo? If I just add the source and build dirs, wouldn't it just report false positives due to code generation for e.g. data classes?
    g
    • 2
    • 18
  • s

    Seri

    10/17/2018, 5:05 AM
    I just watched Dave Ford's amazing talk on React Kotlin from last year(

    https://www.youtube.com/watch?v=FDOECr-sT6U▾

    ) and I was wondering how things have progressed since then. Is there a type-safe way to manipulate CSS yet?
    n
    h
    • 3
    • 2
  • m

    myanmarking

    10/17/2018, 11:53 AM
    is any1 experimenting AS 3.2.1 totally unusable while building a project ?
    k
    a
    +3
    • 6
    • 24
  • t

    tddmonkey

    10/17/2018, 1:43 PM
    I have that every time I see James Van Der Beak on TV 😄
    m
    • 2
    • 2
Powered by Linen
Title
t

tddmonkey

10/17/2018, 1:43 PM
I have that every time I see James Van Der Beak on TV 😄
m

michael aubert

10/17/2018, 2:15 PM
how often is that likely to happen these days, though? 😂
t

tddmonkey

10/17/2018, 2:17 PM
More than you might think!
View count: 2