Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Swift5のOwnership
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
8pockets
August 21, 2018
Programming
1
2k
Swift5のOwnership
8pockets
August 21, 2018
Tweet
Share
Other Decks in Programming
See All in Programming
AI Schema Enrichment for your Oracle AI Database
thatjeffsmith
0
220
2026年 エンジニアリング自己学習法
yumechi
0
120
Honoを使ったリモートMCPサーバでAIツールとの連携を加速させる!
tosuri13
1
170
AIによるイベントストーミング図からのコード生成 / AI-powered code generation from Event Storming diagrams
nrslib
2
1.8k
GISエンジニアから見たLINKSデータ
nokonoko1203
0
200
20260127_試行錯誤の結晶を1冊に。著者が解説 先輩データサイエンティストからの指南書 / author's_commentary_ds_instructions_guide
nash_efp
0
830
Unicodeどうしてる? PHPから見たUnicode対応と他言語での対応についてのお伺い
youkidearitai
PRO
1
1k
生成AIを使ったコードレビューで定性的に品質カバー
chiilog
0
210
HTTPプロトコル正しく理解していますか? 〜かわいい猫と共に学ぼう。ฅ^•ω•^ฅ ニャ〜
hekuchan
2
670
2年のAppleウォレットパス開発の振り返り
muno92
PRO
0
200
フルサイクルエンジニアリングをAI Agentで全自動化したい 〜構想と現在地〜
kamina_zzz
0
400
React 19でつくる「気持ちいいUI」- 楽観的UIのすすめ
himorishige
11
5.9k
Featured
See All Featured
A designer walks into a library…
pauljervisheath
210
24k
Building Applications with DynamoDB
mza
96
6.9k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
287
14k
From π to Pie charts
rasagy
0
120
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
122
21k
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
130
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
9
1.1k
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
0
1.1k
Have SEOs Ruined the Internet? - User Awareness of SEO in 2025
akashhashmi
0
270
Exploring the relationship between traditional SERPs and Gen AI search
raygrieselhuber
PRO
2
3.6k
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
54
Information Architects: The Missing Link in Design Systems
soysaucechin
0
750
Transcript
Swift5ͷOwnership ΑΓࡉ͔͍ϝϞϦཧ
ࣗݾհ • ࢁᏴޗ @8pockets • Python, Go, PHP, Swift, C++
• swiftྺ
࣍ • Swift5ʹ͍ͭͯ • ݱঢ়ͷ՝ͱOwnershipಋೖͷཧ༝ • Ownershipͷ̏ͭͷػೳ
Swift5ʹ͍ͭͯ Early 2019 ϦϦʔε༧ఆ • ABI(Application Binary Interface)ͷ҆ఆԽ • ඪ४ϥΠϒϥϦʹඞཁͱͳΔδΣωϦΫε
• API resilience • Memory ownership model ࢀߟɿhttps://github.com/apple/swift-evolution
Ownershipಋೖͷཧ༝ $16ͷੑೳΛ׆͔͖͠Δ
ݱঢ়ͷ՝ • ࢀরΧϯτͱϢχʔΫੑͷݕࠪΦʔόʔϔου • ͍ͭͰΛίϐʔͰ͖Δঢ়ଶͩͱόοϑΝ͕Ұ ൠʹώʔϓ֬อ͞ΕΔɻελοΫ֬อʹ͢ΔͱΑ Γޮత SwiftͰCOWܕ͕͘ΘΕ͖ͯͨɻ͚Ͳ͍͘ Β͔ͷ͋Δɻ
ݱঢ়ͷ՝ •ίϐʔΦϯϥΠτ (Copy-On-Write) ίϐʔཁٻ͞ΕͯɺίϐʔΛͨ͠;ΓΛͯ͠ɺͱΓ ͋͑ͣݪຊΛͦͷ··ࢀর͢Δɺݪຊ·ͨίϐʔͷ ͲͪΒ͔Λॻ͖͑Α͏ͱͨ࣌͠ʹίϐʔ͕ى͜Δ ͜ΕʹΑͬͯ͋ΔఔͷύϑΥʔϚϯεͷΛΧόʔ ͍ͯͨ͠ɻ ΑΓߴͳνϡʔχϯάΛՄೳʹͨ͠ͷ͕Ownership
Ownershipಋೖͷཧ༝ ͜Ε·ͰϝϞϦίϐʔ͍ͯͨ͠໘ͰɺϦιʔεΛି͠ ͨΓआΓͨΓͰ͖ΔΑ͏ʹͳΓɺΑΓߴʹॲཧ͕ॻ͚ Δ ར༻έʔε • ԻॲཧͳͲͷϦΞϧλΠϜੑΛඞཁͱ͢Δॲཧ • αʔόʔαΠυSwift
Ownershipͷ̏ͭͷػೳ
Ownershipͷ̏ͭͷػೳ • ഉଞଇ - The Law of Exclusivity • shared
- Shared values • ίϐʔෆՄೳͳܕ - moveonly
ഉଞଇ • Swift4ͰϦϦʔεࡁ • ͋Δͷॻ͖ࠐΈΞΫηε͕ഉଞతͰ͋Δ ࣄΛڧ੍͢ΔɻͦͷଞͷΞΫηε͕ಉ࣌ʹੜ ͡ΔࣄΛېࢭ
ഉଞଇ ؔͷJOPVUҾʹมΛ͢ GVODGPP @UNQJOPVU4USJOH @UNQJOPVU4USJOH \^ WBSB4USJOHlUFTU GPP B B
ˠিಥ NVUBUJOHGVODͳϝιουΛݺͿ WBSY FYUFOTJPO*OU\ NVUBUJOHGVODBTTJHO3FTVMU0G @GVODUJPO *OU \ TFMGGVODUJPO ^ ^ YBTTJHO3FTVMU0G\Y ^ˠিಥ
shared GVODTBNQMF WBMVFTIBSFETUSJOH \ WBMVFมMFUͷΑ͏ʹѻΘΕΔɻ ^ ίϐʔ͕Ͱ͖ͳ͍ܕΛ࡞ΕΔΑ͏ʹͳΔ
shared ௨ৗͷҾ ؔΛݺͼग़͢ࡍʹ͕ίϐʔ͞ΕΔͨΊɺ ίετ͕͔͔Δ inoutࢀর ͦͷετϨʔδͷϙΠϯλΛ͚ͩ͢Ͱ͋Γɺ ͦͷΑ͏ͳίϐʔίετ͕͔͔Βͣߴ ॻ͖ࠐΈՄೳ sharedࢀর JOPVUͷಡΈऔΓઐ༻
ݺͼग़͠ଆʹΞϯύαϯυ Λ͚ͭΔඞཁ͕ͳ͍
ίϐʔෆՄೳͳܕ NPWFPOMZTUSVDU)PHF\^ WBSB)PHF B͔ΒCʹϦιʔεͷॴ༗ݖ͕Ҡಈ BࣗಈͰղ์͞ΕΔ WBSCNPWF B ίϯύΠϧΤϥʔ
QSJOU B ίϐʔ͕Ͱ͖ͳ͍ܕΛ࡞ΕΔΑ͏ʹͳΔ
ίϐʔෆՄೳͳܕ มശͰͳ͘ɺʹ͚ͭͨϥϕϧ WBSB)PHF WBSCNPWF B ॴ༗ऀ͕͍ͳ͘ͳͬͨϦιʔεࣗಈͰղ์͞ΕΔ
END