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
What's Up With Swift
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Mert Dumenci
December 14, 2014
Programming
0
120
What's Up With Swift
NSIstanbul Meetup 1.4
Mert Dumenci
December 14, 2014
Tweet
Share
Other Decks in Programming
See All in Programming
Apache Iceberg V3 and migration to V3
tomtanaka
0
170
カスタマーサクセス業務を変革したヘルススコアの実現と学び
_hummer0724
0
730
「ブロックテーマでは再現できない」は本当か?
inc2734
0
1k
AI & Enginnering
codelynx
0
120
フロントエンド開発の勘所 -複数事業を経験して見えた判断軸の違い-
heimusu
7
2.8k
CSC307 Lecture 01
javiergs
PRO
0
690
そのAIレビュー、レビューしてますか? / Are you reviewing those AI reviews?
rkaga
6
4.6k
Rust 製のコードエディタ “Zed” を使ってみた
nearme_tech
PRO
0
200
AIによる開発の民主化を支える コンテキスト管理のこれまでとこれから
mulyu
3
410
開発者から情シスまで - 多様なユーザー層に届けるAPI提供戦略 / Postman API Night Okinawa 2026 Winter
tasshi
0
210
CSC307 Lecture 09
javiergs
PRO
1
840
IFSによる形状設計/デモシーンの魅力 @ 慶應大学SFC
gam0022
1
310
Featured
See All Featured
What’s in a name? Adding method to the madness
productmarketing
PRO
24
3.9k
Context Engineering - Making Every Token Count
addyosmani
9
660
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
1
440
The Art of Programming - Codeland 2020
erikaheidi
57
14k
Building the Perfect Custom Keyboard
takai
2
690
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
0
180
The innovator’s Mindset - Leading Through an Era of Exponential Change - McGill University 2025
jdejongh
PRO
1
93
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
The Illustrated Children's Guide to Kubernetes
chrisshort
51
51k
The browser strikes back
jonoalderson
0
390
The Spectacular Lies of Maps
axbom
PRO
1
520
VelocityConf: Rendering Performance Case Studies
addyosmani
333
24k
Transcript
What’s up with Swift? $ diff Objective-C Swift
“Objective-C without the C”
“Objective-C without the C” A new language
Objective-C is heavily influenced by Smalltalk Objective-C is based on
messaging Objective-C is reflective
Swift is not heavily influenced by Smalltalk Swift is not
based on messaging Swift is limited in reflection
<objc/runtime.h>
objc_msgSend
Objective-C is dynamic (fun!) and safe enough by design
Swift is static and safe by design
Objective-C relies on the runtime for a lot of things
This makes it flexible But also hard to statically analyse
Swift relies on the compiler for a lot of things
This makes it not so flexible But also easy to statically analyse
Swift is not just a changed syntax
It’s a philosophy change
Swift is safe
Swift is concise
Swift is multi paradigm
Objective-C nil eats messages
There’s usually no need for explicit value existence checks
If nil means non-existent, so how do you represent existent
keys with no value in hashes?
[NSNull null]
@property (nonatomic, retain) NSMutableArray *array; [self.array addObject:@1]; NSNumber *value =
self.array.firstObject; Why is value nil?
nil, NSNull, silent failure
Optionals
enum Optional<T> { case None case Some(T) }
None
None
None
Type inference
let name = “Mert" let cities = ["Istanbul": 14_160_167, "Copenhagen":
559_557, "Tokyo": 13_350_000] let image = UIImage(named: "NSIstanbul")
Generics
None
func map<T, U>(array: [T], transform: (T) -> U) -> [U]
Theorems for free! Philip Wadler
Mutability as a language feature
Value types
First class functions
Pattern matching
…and many more
Swift is modern
Thanks
@mertdumenci
A lot of this presentation is from Functional Programming in
Swift — read it!
Couple of things
Objective-C is still a super awesome language, and it’s not
going anywhere anytime soon. It’s still incredibly relevant.
Swift is a concise and clean language. This doesn’t mean
it’s similar to JavaScript in any way. Don’t write JavaScript in Swift.
Swift has a long way to go. If you need
good reliability, use Objective-C.