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
Summon Rust from Swift
Search
Takuma Shimizu
December 06, 2019
Programming
0
670
Summon Rust from Swift
Takuma Shimizu
December 06, 2019
Tweet
Share
More Decks by Takuma Shimizu
See All by Takuma Shimizu
Swift Attributes
hokuron
0
430
Peek in Calendar implementation of swift-foundation
hokuron
0
180
MVVM
hokuron
0
50
Opaque Result Type in Swift with Rust
hokuron
0
160
Generalized accessors
hokuron
0
81
Ownership of Swift as seen from iteration and Rust
hokuron
1
680
Clean Architecture 3
hokuron
0
54
Clean Architecture 2
hokuron
0
69
Create MLで犬と猫の肉球を学習
hokuron
0
100
Other Decks in Programming
See All in Programming
0から始めるモジュラーモノリス-クリーンなモノリスを目指して
sushi0120
0
170
マッチングアプリにおけるフリックUIで苦労したこと
yuheiito
0
250
What's new in Adaptive Android development
fornewid
0
120
CLI ツールを Go ライブラリ として再実装する理由 / Why reimplement a CLI tool as a Go library
ktr_0731
3
720
The Evolution of Enterprise Java with Jakarta EE 11 and Beyond
ivargrimstad
0
560
QA x AIエコシステム段階構築作戦
osu
0
220
テスターからテストエンジニアへ ~新米テストエンジニアが歩んだ9ヶ月振り返り~
non0113
2
240
#QiitaBash TDDで(自分の)開発がどう変わったか
ryosukedtomita
1
110
What's new in AppKit on macOS 26
1024jp
0
180
MCP連携で加速するAI駆動開発/mcp integration accelerates ai-driven-development
bpstudy
0
130
Reactの歴史を振り返る
tutinoko
1
150
React 使いじゃなくても知っておきたい教養としての React
oukayuka
15
4.3k
Featured
See All Featured
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
16k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3.3k
Fashionably flexible responsive web design (full day workshop)
malarkey
407
66k
Adopting Sorbet at Scale
ufuk
77
9.5k
Learning to Love Humans: Emotional Interface Design
aarron
273
40k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
8
720
Rebuilding a faster, lazier Slack
samanthasiow
83
9.1k
Imperfection Machines: The Place of Print at Facebook
scottboms
267
13k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
331
22k
Visualization
eitanlees
146
16k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
50
5.5k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
130
19k
Transcript
4VNNPO3VTU GSPN4XJGU 4)*.*;65BLVNB !IPLVSPO
4VNNPO3VTU GSPN4XJGU
4XJGUQFSGPSNTGVODUJPOT XSJUUFOCZ3VTU
)PX w 6TF3VTUT''*GFBUVSF w 'PSFJHO'VODUJPO*OUFSGBDF w &YQPSU3VTUDPEFTBT$DPEFT w GVODUJPOTBOETUSVDUT FUD
w #SJEHFUIF$DPEFTJOUP4XJGU w FH 7JBCSJEHJOHIFBEFS I
IUUQTHJUIVCDPNSB%J⒎FSFODF,JU
IUUQTHJUIVCDPNSB%J⒎FSFODF,JU
TUEDMPOF$MPOF 4XJGU w $MPOFUIFJNQMFNFOUBUJPOXSJUUFOCZ4XJGU w 4PpOJTIFE3VTUDPEFCBTFJT4XJGUZ w 6TFDMBTTFTBOETIBSFUIFJSJOTUBODFTCFUXFFO DPMMFDUJPOPCKFDUT w
3FQSPEVDFTJNQMZUIFBCPWFXJUI3VTUCSJOHT PWFSIFBETBUSVOUJNF w #SJEHJOH4XJGUUP$NBZCFBCMFUPCFFYQFOTJWF
%FNP
Impl DeepDiff w 4IBSFJOTUBODFTPGBDMBTTCFUXFFO POFDictionaryBOEUXPArrayT w .VUBUFUIFJOTUBODFTUIBUUBLFGSPNUIF DictionaryBOEArrayT
struct Rc<T> w 3FGFSFODF$PVOUFE w Arc<T>"VUPNBUJD"UPNJDBMMZ3FGFSFODF$PVOUFE w 4IBSFBWBMVFCFUXFFOUXPPSNPSFPXOFST w 3FBMJ[FGFBUVSFTMJLFBOJNNVUBCMFDMBTT
w #SJOHPWFSIFBEBUSVOUJNF
struct RefCell<T> • struct Cell<T> • Rc<RefCell<T>> w 3FBMJ[FGFBUVSFTMJLFBDMBTTNVUBUJPO w
*O4XJGU BTJNJMBSUPBOPCKFDUPGBDMBTTTUPSFE CZletQSPQFSUZXJUIJOBTUSVDU w 1VUP⒎CPSSPXDIFDLVOUJMSVOUJNF w #SJOHPWFSIFBEBUSVOUJNF
$CSJEHJOH w $PFSDJPO *NQMJDJUUZQFDPOWFSTJPO • ⭕ String Unsafe<CChar>
• ⭕ Array<T> UnsafePointer<T> • ❌ Array<String> UnsafePointer<UnsafePoint<CChar>> w "OZXBZUIFTFBSFFYQFOTJWF
%FNP
3FDBQ w 3VTUJTDBQBCMFPG''* w ''*FYQPSUT$JOUFSGBDF w 4XJGUVTFTUIF$JOUFSGBDF w 3VTUJTWFSZGBTU FWFOUIPVHIOPU4XJGUZ3VTU