From time to time, I got into a situation that I need to override initializers, inherited from a superclass, for my own class. For instance:
It happened when I was thinking where to put a constant property of the default debug log level in my iOS project. The project contains a host app and an…
This article was written based on my personal perspective. Occasionally I found the usage of lazy variables from pull requests, and most of the times the thread safety issue of them was not properly handled. I…
Foreword
If you encounter problems of properly setting/adding attributes to NSAttributedString while the string is composed of multibyte character sets, or MBCS for short, then this article is for you.
git remote update origin — prune # remove branches that are no longer available in origin
git merge — squash <branch> # merge all commits as one commit
偶爾,我會遇見宣告成 [String: Any]的參數。
[String: Any]
From time to time I encounter parameters declared as [String: Any].
雖然這樣的宣告提供了字典類別攜帶各種類別的值的彈性,但取值時卻常帶來麻煩。也許你曾讀到過類似的原始碼:
Due to the need of intercepting https requests to investigate security issues on iOS handsets, I was looking for solutions for such purpose. Charles is one of the most-famous pieces of software for the category. Indeed, it’s…