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
Generalized accessors
Search
Takuma Shimizu
March 27, 2019
Programming
93
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Generalized accessors
Takuma Shimizu
March 27, 2019
More Decks by Takuma Shimizu
See All by Takuma Shimizu
RailsのValidatesをSwift Macrosで再現してみた
hokuron
0
200
Swift Attributes
hokuron
0
480
Peek in Calendar implementation of swift-foundation
hokuron
0
280
MVVM
hokuron
0
86
Summon Rust from Swift
hokuron
0
730
Opaque Result Type in Swift with Rust
hokuron
0
200
Ownership of Swift as seen from iteration and Rust
hokuron
1
760
Clean Architecture 3
hokuron
0
76
Clean Architecture 2
hokuron
0
100
Other Decks in Programming
See All in Programming
Compiling a real-world CLI tool to native with Static Hermes
tmikov2023
0
120
ChromeでローカルLLM
ryu1013
0
140
3回つくってわかった、 定期実行ジョブ基盤の本質情報
takai
0
460
作って学ぶSpring BootのAuto Configuration / JJUG Night Seminar 2026-10-19
rshindo
0
150
iOS 27でニュースアプリはどう変わる!? 〜日経電子版の新機能対応と、開発事例から〜
lynnswap
7
13k
re:Inventに行く前に知っておきたい現地参加のノウハウ
nokomoro3
0
430
SREの越境 / SRE Collaboration
y0hgi
2
310
[Dev Group Paris Octobre 26] Agentforce, SIforce, Claudeforce, Slackbot… on s'y retrouve ?
nabondance
0
110
HTML-in-Canvasで作る未来のWeb UI表現
clockmaker
5
5.1k
When benchmarks go bad - what I learned from measuring performance wrong
hollycummins
0
220
Next.js: The final boss of Web Performance
guaca
0
260
TechTown - Creating Composable Callables in Contemporary C++
rollbear
0
130
Featured
See All Featured
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
730
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
710
The Anti-SEO Checklist Checklist. Pubcon Cyber Week
ryanjones
0
270
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
2
480
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
3.2k
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.9k
Making Projects Easy
brettharned
120
6.8k
Darren the Foodie - Storyboard
khoart
PRO
4
4k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
128
56k
Automating Front-end Workflow
addyosmani
1369
210k
GraphQLの誤解/rethinking-graphql
sonatard
75
12k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
47
8.4k
Transcript
subscrit get set
get let nums = Array(0..<10) let x10 = nums[3] *
10 // `get` print(num) subscript(index: Int) -> Element { get { let element = // `index` return element // } set { ... } }
set var nums = Array(0..<10) let num = nums[3] nums[3]
= num * 10 // `set` print(num) subscript(index: Int) -> Element { get { ... } set(newValue) { // `newValue` // buffer = newValue } }
Swift 4.2 mutableAddressWithPinnedNativeOwner Swift 5 read , modify yield co-routine
read // CoreAudio.swift subscript(index: Index) -> Element { _read {
yield ((_audioBuffersPointer + index).pointee) } } modify // Array.swift subscript(index: Int) -> Element { _modify { let address = _buffer.subscriptBaseAddress + index yield &address.pointee } }
yield subscript(index: Int) -> inout Element {} inout Rust Lifetime
Rust Swift
yield
!