Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Kotlin Dynamic type
Search
coe
September 26, 2023
Technology
440
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Kotlin Dynamic type
集まれSwift好き!Swift愛好会 vol.77 @ DeNA
2023/09/26
coe
September 26, 2023
More Decks by coe
See All by coe
すべてのヘルスケアデータを紐解く.pdf
coe
0
3.6k
About HealthKit nutrition
coe
0
510
iOSDC 2023 Web in tvOS and watchOS
coe
1
1.2k
iOSDC 2023 Push To Talk
coe
1
2.9k
iOSDC手で触れずにアプリを動かす技術
coe
1
2.5k
iOSDC令和時代のXML処理を考える
coe
3
3.3k
iOSDC 2021 Restore
coe
6
2.5k
詳解Storyboard
coe
7
4.2k
あなたの知らない連絡先の世界
coe
15
8.5k
Other Decks in Technology
See All in Technology
Don't write the architecture only in the prompt.
neohsu
0
290
AI AgentによるEmbedded SREの取り組み
tgidgd
1
320
Vibe-to-Spec開発_実践ガイド
happysamurai294
0
140
Jev の中身は50行で再現できる。でも本物との差はどこにあるのか
hisuzuya
0
280
Consistency for mere mortals - A gentle guide to consistency
ufried
0
110
あなたのDartコードは丸見えかもしれない ~reFlutterで暴くFlutterアプリの中身と多層防御~
zozotech
PRO
0
740
Agent Loopを組み込んだ アンビエントなAI機能を実現する / Ambient AI fetures with Agent Loop
nekorush14
0
130
キヨさん、67歳。AIコーディングエージェントに挑む
happysamurai294
0
140
(swiftc) NonCopyableとライフタイム修飾子
teamhimeh
0
160
基本から分かる!AWSセキュリティ運用の考え方と任せ方
cmusudakeisuke
1
340
kintoneで在庫管理システムを作るときの要件定義・設計ポイント
kai0707
0
200
視野はAIに、視座は人に / ai-for-breadth-humans-for-perspective
nkzn
6
2.7k
Featured
See All Featured
Odyssey Design
rkendrick25
PRO
2
910
WENDY [Excerpt]
tessaabrams
14
40k
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
6
1.3k
Chasing Engaging Ingredients in Design
codingconduct
0
380
The Curse of the Amulet
leimatthew05
3
16k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
Have SEOs Ruined the Internet? - User Awareness of SEO in 2025
akashhashmi
0
540
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
123
22k
The Spectacular Lies of Maps
axbom
PRO
1
1.1k
Code Reviewing Like a Champion
maltzj
529
40k
Typedesign – Prime Four
hannesfritz
42
3.2k
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
290
Transcript
ڧ݄ %ZOBNJDUZQF ू·Ε4XJGU͖ʂ4XJGUѪձWPM ू·Ε,PUMJO͖ʂ,PUMJOѪձWPM!%F/"
w ڧ w J04ΤϯδχΞ
%ZOBNJDUZQF
w ڧ w J04Τ ϯδχ Ξ
%ZOBNJD UZQF
fun dynamicFun(x: dynamic): Unit { val dyn: dynamic = ...
} ,PUMJO%ZOBNJDUZQF
%ZOBNJDUZQF
%ZOBNJDUZQF w EZOBNJDܕ w WBMEZOEZOBNJDʜ w ͳΜͰೖΔ
fun dynamicFun(x: dynamic): Unit { }
fun dynamicFun(x: dynamic): Unit { } fun anyFun(x: Any): Unit
{ }
fun dynamicFun(x: dynamic): Unit { x.god } fun anyFun(x: Any):
Unit { x.god // ←ίϯύΠϧΤϥʔ }
%ZOBNJDUZQF w EZOBNJDܕ w WBMEZOEZOBNJDʜ w ͳΜͰೖΔ w ܕνΣοΫΛߦΘͳ͍ʢίϯύΠϧΤϥʔʹͳΒͳ͍ʣ
// xHuman fun dynamicFun(x: dynamic): Unit { x.back.left.left.up.scratch() } class
Back { val left: Back get() = Back() val right: Back get() = Back() val up: Back get() = Back() val down: Back get() = Back() fun scratch(): Unit { println(“ຬʂ”) } } class Human { val back = Back() }
%ZOBNJDUZQF w EZOBNJDܕ w WBMEZOEZOBNJDʜ w ͳΜͰೖΔ w ܕνΣοΫΛߦΘͳ͍ʢίϯύΠϧΤϥʔʹͳΒͳ͍ʣ w
ࣗ༝ʹϓϩύςΟؔΛݺΔ w EZOBNJDܕͷϓϩύςΟؔͷϦλʔϯEZOBNJDܕ
fun dynamicPlus(x: dynamic, y: dynamic): Unit { x + y
}
fun dynamicPlus(x: dynamic, y: dynamic): Unit { x + y
// 3 } dynamicPlus(1, 2)
fun dynamicPlus(x: dynamic, y: dynamic): Unit { x + y
// ڧ } dynamicPlus(“”, “ڧ”)
fun dynamicPlus(x: dynamic, y: dynamic): Unit { x + y
// iOSΤϯδχΞ } dynamicPlus(“iOS”, “ΤϯδχΞ”)
fun dynamicPlus(x: dynamic, y: dynamic): Unit { x + y
// 105ΤϯδχΞ } dynamicPlus(105, “ΤϯδχΞ”)
%ZOBNJDUZQF w EZOBNJDܕ w WBMEZOEZOBNJDʜ w ͳΜͰೖΔ w ܕνΣοΫߦΘͳ͍ʢίϯύΠϧΤϥʔʹͳΒͳ͍ʣ w
ࣗ༝ʹϓϩύςΟؔΛݺΔ w EZOBNJDܕͷϓϩύςΟEZOBNJDܕ w EZOBNJDಉ࢜ͷܭࢉՄೳ
͍͢͝ʂ
͡ΊΑ͏
,PUMJO+4
IUUQTLPUMJOMBOHPSHEPDTEZOBNJDUZQFIUNM %ZOBNJDUZQF
None