Understand your Mac and iPhone more deeply by tracing the evolution of Mac OS X from prelease to Swift. John Siracusa delivers the details.
You've got two main options:
| class SwiftFormat < Formula | |
| desc "Formatting technology for Swift source code" | |
| homepage "https://github.com/apple/swift-format" | |
| url "https://github.com/apple/swift-format.git", :branch => "swift-5.1-branch" | |
| head "https://github.com/apple/swift-format.git" | |
| depends_on :xcode => ["11.0", :build] | |
| def install | |
| system "swift", "build", "--configuration", "release", | 
| // This file is based largely on the Runtime package - https://github.com/wickwirew/Runtime | |
| extension KeyPath { | |
| var fieldName: String? { | |
| guard let offset = MemoryLayout<Root>.offset(of: self) else { | |
| return nil | |
| } | |
| let typePtr = unsafeBitCast(Root.self, to: UnsafeMutableRawPointer.self) | |
| let metadata = typePtr.assumingMemoryBound(to: StructMetadata.self) | 
| ACTIVITY_LOG_STDERR | |
| AEConvertBookmarksToAliasesHack | |
| AEDebugFull | |
| AEDebugReceives | |
| AEDebugSends | |
| ALLOWED_GPU_IDS | |
| APPLE_FRAMEWORKS_ROOT | |
| ARCH | |
| ASL_DISABLE | |
| ASL_QUOTA_DISABLED | 
| import Foundation | |
| func examine(_ str: String) { | |
| print("\"\(str)\"") | |
| print("bridges as: \(type(of: str as NSString))") | |
| str.withCString { | |
| print("inits an NSString as: \(type(of: NSString(cString: $0, encoding: String.Encoding.ascii.rawValue)!))") | |
| } | |
| print("\n") | |
| } | 
| import UIKit | |
| import ObjectiveC.runtime | |
| /// An enum that displays UIKitCore's `UIDebuggingInformationOverlay`. | |
| enum DebuggingOverlay { | |
| /// Shows the `UIDebuggingInformationOverlay`. | |
| @available(iOS 13, *) | |
| static func show() { | |
| struct Once { |