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
kotlin-native
  • m

    molikto

    04/01/2018, 4:24 PM
    hello. is there any way to add c code and compile together with Kotlin Native? I have some code written in Kotlin + JNI and want to convert it to Kotlin Native
    o
    • 2
    • 2
  • j

    J-Rojas

    04/01/2018, 11:03 PM
    Where should we supply suggestions for native library bindings? sqlite doesn't appear to be supported even though it is a core library on iOS.
    o
    • 2
    • 1
  • n

    napperley

    04/01/2018, 11:36 PM
    Are there plans to have a Kotlin Native bindings repository for common C libs (something that is a mixture of definitely typed and maven repos but for Kotlin Native)?
    👍 5
    h
    • 2
    • 1
  • a

    anidotnet

    04/02/2018, 1:04 PM
    Though I have
    http_proxy
    env variable set up properly
    o
    a
    • 3
    • 29
  • a

    Aregev2

    04/03/2018, 12:45 AM
    Can I use custom C code to interop with k/n (need to interop with the direct C libs such as treads.h, time.h ect....) Will it work?
    j
    o
    • 3
    • 3
  • a

    Aregev2

    04/03/2018, 2:59 PM
    Trying to mess up with klibs, made my first "util" library that has few functions, compiled it to a klib library, but I have no idea how to acess its functions in code, can someone help?
    j
    • 2
    • 10
  • j

    J-Rojas

    04/03/2018, 3:10 PM
    For accessing SQLite, I had to use the following.
    val ppDB = cValuesOf<sqlite3>(null)
    sqlite3_open(filePath, ppDB)
    ...
    val pDB = ppDB.getPointer(memScope).pointed.value
    sqlite3_close(pDB)
    Is there a plan to make interop pointers easier to grok? Maybe offer a language level */& operator like C?
    o
    s
    • 3
    • 2
  • s

    sksk

    04/03/2018, 7:27 PM
    is there a way to get both working on windows ? it works fine on macOS but on windows i get: unresolved reference
    import platform.OpenGL.*
    import platform.OpenGLCommon.*
    o
    • 2
    • 2
  • a

    albertgao

    04/03/2018, 10:25 PM
    Anyone gets this error?
    ld: symbol(s) not found for architecture armv7
    j
    o
    • 3
    • 3
  • j

    J-Rojas

    04/04/2018, 4:13 AM
    I found more objective-c Foundation library conversions in the K/N runtime. https://github.com/JetBrains/kotlin-native/blob/0bfa68cf037fc6d6141f22cb6e9b9390e989f64d/runtime/src/main/cpp/ObjCExportCollections.mm Could we have these exposed as part of some interop API?
    s
    s
    • 3
    • 7
  • j

    J-Rojas

    04/04/2018, 3:28 PM
    I'm attempting to use some Objective-C libraries in a klib. During the last phases of compilation, I receive this compiler error. Any ideas why?
    [system.err] error: can't produce platform.Foundation.NSArray to framework API
    s
    • 2
    • 2
  • g

    gmaciel

    04/05/2018, 1:16 PM
    Anything i’m missing here?
    v
    g
    o
    • 4
    • 8
  • r

    rellenberger

    04/05/2018, 3:09 PM
    Is there any plans for kotlin to generate Swift libraries?
    s
    • 2
    • 1
  • m

    mutexkid

    04/05/2018, 4:22 PM
    are we meant to work with kotlin/native using gradle from within Clion, or IntelliJ (or are either workable)?
    o
    • 2
    • 2
  • m

    mutexkid

    04/05/2018, 4:23 PM
    If Clion, are there any options for integrating gradle into the IDE nicely, or command line only?
    g
    j
    k
    • 4
    • 7
  • m

    molikto

    04/05/2018, 4:32 PM
    how can I include a library as a submodule and use relative include folders?
    o
    m
    • 3
    • 2
  • m

    molikto

    04/05/2018, 6:03 PM
    target('macbook') { linkerOpts '-framework Cocoa -framework OpenGL -framework IOKit -framework CoreVideo' }
    s
    • 2
    • 1
  • m

    molikto

    04/05/2018, 6:11 PM
    also @sksk do you know how to setup IntelliJ IDEA so the generated c_introp code can be supported?
    s
    • 2
    • 1
  • s

    SrSouza

    04/06/2018, 7:12 AM
    Is possible in the future kotlin has interop with Dart to work with Flutter for Fuchsia target?
    🤔 3
    😎 5
    📳 2
    🎯 7
    :no_red: 4
    g
    j
    +2
    • 5
    • 15
  • y

    yusuf3000

    04/08/2018, 10:48 AM
    I’m using the
    Mockk
    testing framework in my unit tests in my common module. They compile and run fine on the android platform, but I get compilation issues with unresolved references for any MockK objects when running the tests on the ios platform. Is this a limitation with k/n, or is there something I can do in order for this to work?
    o
    • 2
    • 5
  • c

    chi

    04/08/2018, 2:45 PM
    Hi, if I want to run the samples in Kotlin native, can I go about it using Intellij?
    a
    • 2
    • 1
  • j

    J-Rojas

    04/08/2018, 10:11 PM
    How would I determine the ObjC object type within K/N? I have a method from an ObjC module that returns an 'id' return type. I need to cast it to the appropriate NS class, then to a Kotlin analogue. The klib module binding returns a 'ObjCObject?' from that method.
    o
    • 2
    • 1
  • s

    spierce7

    04/09/2018, 12:57 AM
    Do generics work when using a Kotlin native library in swift? I've read that they don't work. Is this planned?
    j
    • 2
    • 1
  • v

    Vlad Drahnea

    04/09/2018, 9:12 AM
    Hey guys, probably a dumb question here, but, can I use intellij IDEA while testing with kotlin.test? Seems like IDEA doesn’t see annotations (
    @Test
    ) declaration there. Is it possible to make it work so?
    g
    • 2
    • 8
  • a

    Alexander Stark

    04/09/2018, 10:45 AM
    Hi, is it possible to consume a Kotlin/Native klib in a Kotlin module?
    o
    s
    g
    • 4
    • 15
  • v

    vincent.desmet

    04/10/2018, 2:09 PM
    Are there any plans for supporting 32-bit iOS devices?
    s
    o
    b
    • 4
    • 3
  • d

    dalexander

    04/10/2018, 6:49 PM
    Out of curiosity, are there bindings for SIMD intrinsics (SSE, AVX, etc?) for Kotlin Native yet? A quick web search yields nothing. Or would it make more sense to just import and use normal C intrinsics?
    o
    • 2
    • 1
  • j

    J-Rojas

    04/11/2018, 2:38 AM
    Is there support in the konan lldb python evaluator for method or property evaluation? I can print local vars and vals but derefencing a Kotlin object yields:
    error: member reference type 'ObjHeader *' is a pointer; did you mean to use '->'?
    error: incomplete definition of type 'ObjHeader'
    forward declaration of 'ObjHeader'
    o
    • 2
    • 1
  • o

    olonho

    04/11/2018, 7:14 PM
    https://blog.jetbrains.com/kotlin/2018/04/kotlinnative-plugin-for-appcode/
    🎉 21
    👏 6
    🤘 11
    q
    s
    +3
    • 6
    • 8
  • d

    drofwarcs

    04/11/2018, 11:05 PM
    I probably missed this somewhere, but how do we wire up a UIView element in a storyboard, such as a button, to a variable in a kotlin class thats been annotated with
    @ObjCOutlet
    or a function thats been annotated with
    @ObjCAction
    ?
    v
    • 2
    • 2
Powered by Linen
Title
d

drofwarcs

04/11/2018, 11:05 PM
I probably missed this somewhere, but how do we wire up a UIView element in a storyboard, such as a button, to a variable in a kotlin class thats been annotated with
@ObjCOutlet
or a function thats been annotated with
@ObjCAction
?
v

Vyacheslav Karpukhin [JB]

04/11/2018, 11:08 PM
Unfortunately, since it's impossible to extend Xcode's Interface Builder, the only way is to edit the storyboard's XML manually to add the connection between the outlet/action and the UI component.
d

drofwarcs

04/11/2018, 11:11 PM
Good to know. Thx
View count: 3