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
Optional 遇到的問題 - 公司內分享會
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Lihsuan Chen
August 18, 2016
Programming
160
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Optional 遇到的問題 - 公司內分享會
這週主題是專案上使用 Swift 的 optional 時所碰到的問題。
包含了使用 [unowned self] 以及 @IBOutlet 時碰到的問題與解決的方式。
Lihsuan Chen
August 18, 2016
More Decks by Lihsuan Chen
See All by Lihsuan Chen
iPlayground 2025 - 接⼿ 10年⼤雜燴:專案現代化與產品開發的挑戰
vc7
0
190
The UX thinking of PAY ID
vc7
2
510
From Onboarding to Value Delivering in iOS
vc7
0
310
Merciless Refactoring
vc7
0
830
Protocol 的實例、測試和心得
vc7
2
850
共有経済
vc7
0
210
.gitignore
vc7
1
130
Git Workshop 03
vc7
0
160
Git Workshop 02
vc7
0
150
Other Decks in Programming
See All in Programming
Welcome to the "Parametricity" 🏙️ − Generic だけど Specific な世界 −
guvalif
PRO
1
140
Go1.27で導入されるジェネリクスメソッドでできること
mackee
0
260
OS アップデート対応の取り組み方がもっと共有されてほしい
andpad
0
110
LLMによるContent Moderationの本番運用の裏側と品質担保への挑戦
suikabar
3
840
コーディングルールの鮮度を保ちたい for SRE NEXT 2026 / keep-fresh-go-internal-conventions-sre-next-2026
handlename
0
130
LaravelLive Japan の裏方のすべて — 第188回 PHP勉強会@東京 (2026-06-24)
suguruooki
2
150
初めてのKubernetes 本番運用でハマった話
oku053
0
120
AIエージェントで 変わるAndroid開発環境
takahirom
2
470
トークンをケチるな、設計しろ:GitHub Copilotを賢く使うコンテキスト戦略
ochtum
0
300
ランチタイムLT会3周年!ランチタイムLT会を3年間続けられたお話
y0hgi
1
140
1B+ /day規模のログを管理する技術
broadleaf
0
130
AI駆動開発を妨げる技術的負債の解消アプローチ / ai-refactoring-approach
minodriven
17
8.8k
Featured
See All Featured
The browser strikes back
jonoalderson
0
1.4k
How to Align SEO within the Product Triangle To Get Buy-In & Support - #RIMC
aleyda
2
1.6k
Prompt Engineering for Job Search
mfonobong
0
370
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
<Decoding/> the Language of Devs - We Love SEO 2024
nikkihalliwell
1
270
Bootstrapping a Software Product
garrettdimon
PRO
307
120k
Getting science done with accelerated Python computing platforms
jacobtomlinson
2
260
How to Ace a Technical Interview
jacobian
281
24k
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
1
1.3k
Tips & Tricks on How to Get Your First Job In Tech
honzajavorek
1
560
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
133
19k
Faster Mobile Websites
deanohume
310
32k
Transcript
遇到的問題 Optional 陳 澧萱 @ 午餐分享會 2016/08/18
目錄 • [unowned self] • @IBOutlet త !
[unowned self]
Crash TFMGඃᬶ์ޙ ࡏDMPTVSFཫݺڣTFMGDSBTI ʢᙛ൛ຊҎ্ʣ
解決方法 Ŏ አ[weak self] Ŏ 矑茐አguard letᴠ纠
@IBOutlet 的 !
@IBOutlet Ŏ 䨝ڊԪጱ碻秚牫 Ŏ viewDidLoad()ฎloadView()ԏ獮 Ŏ ౮㹓虋碍ಅࣁጱᇔկᤩ朰硯ധԧ @IBOutlet var messageLabel:
UILabel!
結語 Ŏ ဳLPSOLFLWO\XQZUDSSHGRSWLRQDO Ŏ 胼犋ᥝአ牧疰犋ᥝአ Ŏ ဳᇔկጱOLIHF\FOH牧犋ᥝॡፘמਥොጱ