Failed to register for BoringSSL log debug updates

UPDATE There’s actually a very convenient way to silence certain logs for a specific simulator: xcrun simctl spawn booted log config –subsystem com.apple.network –category boringssl –mode level:off It is also recommended to silence other common non-important logs as well: xcrun simctl spawn booted log config –subsystem com.apple.CoreBluetooth –mode level:off xcrun simctl spawn booted log config … Read more

Barcode on swift 4

I figured it out but Apple didn’t make it so obvious. The callback function from the delegate AVCaptureMetadataOutputObjectsDelegate has been renamed and the parameter names are different! So, replace func captureOutput(_ captureOutput: AVCaptureOutput!, didOutputMetadataObjects metadataObjects: [Any]!, from connection: AVCaptureConnection!) to func metadataOutput(_ output: AVCaptureMetadataOutput, didOutput metadataObjects: [AVMetadataObject], from connection: AVCaptureConnection) My view controller is now … Read more

Simultaneous accesses to 0x1c0a7f0f8, but modification requires exclusive access error on Xcode 9 beta 4

I think this ‘bug’ may be a Swift 4 “feature”, specifically something they call “Exclusive access to Memory”. Check out this WWDC video. Around the 50-minute mark, the long-haired speaker explains it. https://developer.apple.com/videos/play/wwdc2017/402/?time=233 You could try turning the thread sanitizer off in your scheme settings if you’re happy to ignore it. However, the debugger is … Read more

Use the increased navigation-bar title in iOS 11

The only change done to UINavigationBar API for iOS 11 is prefersLargeTitles. Documentation here: https://developer.apple.com/documentation/uikit/uinavigationbar/ You can do it to your own apps with one small change: check “Prefers Large Titles” for your navigation bar in IB, or if you prefer to do it in code using: navigationController?.navigationBar.prefersLargeTitles = true If you need to change … Read more

navigation bar rightbaritem image-button bug iOS 11

Reason The problem appears because from ios 11 UIBarButtonItem uses autolayout instead of dealing with frames. Solution You should add width constraint for this image-button if you use Xcode 9. button.widthAnchor.constraint(equalToConstant: 32.0).isActive = true button.heightAnchor.constraint(equalToConstant: 32.0).isActive = true PS button is not UIBarButtonItem, it is UIButton inside UIBarButtonItem. You should set constraint not for UIBarButtonItem, … Read more

“This function declaration is not a prototype” warning in Xcode 9

The block declaration with empty parenthesis: void (^)() has the same semantics as a function pointer with empty parenthesis: void (*)() It does not mean that there are no arguments. It means the arguments are not specified, therefore it opens the way to bugs since you can call it in the following ways: void (^block)() … Read more