Author: Chris Lattner
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Playground - noun: a place where people can play | |
import UIKit | |
var str = "Hello, playground" | |
enum TimeIntervalUnit { | |
case Seconds, Minutes, Hours, Days, Months, Years | |
func dateComponents(interval: Int) -> NSDateComponents { |
Use this file to track all dependencies required by this project.
- Added because of its MultipartFormData implementation
- License: MIT
This breakpoint provides an easy way to track view controller deinitialization (deallocation) in UIKit-based applications. This can help finding memory leaks caused by retain cycles preventing view controllers from being deinitialized when dismissed or popped.
From Cédric Luthi's tweet in 2017:
Useful Xcode breakpoint. When you dismiss a controller and you don’t hear the pop sound (or see the log), you probably have a retain cycle.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Combine | |
import ObjectiveC | |
import UIKit | |
typealias TraitCollectionChange = (UITraitCollection, previous: UITraitCollection?) | |
private typealias TraitChangeSubject = PassthroughSubject<TraitCollectionChange, Never> | |
private var traitSubjectKey = "_voodoo_trait_subject" | |
private var swizzlingPerformed = false |