99 posts tagged ‘Programming’
CloudKit Reference and Index Issues
Kuba Suder: CloudKit also automatically creates indexes for each field in each record type - when you’re done with development, you can delete some indexes that you won’t need so they don’t waste space in the production database. Apple: A request to fetch records performs a query on indexed fields for a particular record type. […]
Problematic Swift Concurrency Patterns
Matt Massicotte: I think the vast majority of the time, a global actor should be applied to the type as a whole, not to individual properties.[…]But, while detached does prevent isolation inheritance, it also does other stuff too. Detached tasks do not inherit priority or task-local values. Instead, think about a nonisolated function.[…]I think MainActor.run […]
Swift Format in Xcode 16
Sarah Reichelt (Mastodon): In Xcode 16, Apple quietly introduced the ability to format your Swift files using Swift Format. I’m a long-time user of SwiftLint, but having such a tool built into Xcode would be a great convenience, so I decided to give it a try. Here is my description of why I use such […]
Data Tracking and Notifications in Core Data and SwiftData
Fatbobman (Mastodon): [prepareForDeletion is called] when the managed object is about to be deleted, typically used for cleaning up resources or manually managing relationships. Note that this method is triggered before validateForDelete. If the deletion operation fails due to validation failure, changes made in this method may be rolled back.[…]However, because these operations are extensions […]
Swift Proposal: Integer Generic Parameters
SE-0452 (via Steve Canon): Swift does not currently support fixed-size or fixed-capacity collections with inline storage. (Or at least, it doesn’t do so well, not without forming a struct with some specific number of elements and doing horrible things with withUnsafePointer to handle indexing.) Most of the implementation of something like a fixed-size array, or […]
How to Use Cursor for iOS Development
Thomas Ricouard: Recently, there’s been much talk and fuss about AI, and whether or not it can improve your development workflow. I wanted to touch base about how AI and its implementation in Cursor have been significantly improving my speed and efficiency. In short, Cursor is a fork of VSCode with many code editing AI-assisted […]
GitHub Copilot for Xcode
Frederic Lardinois (MacRumors, Hacker News): Microsoft-owned GitHub is bringing Copilot to Apple’s Xcode environment for the first time. Now in public preview, this will allow developers who build apps in Apple’s IDE with the assistance of Copilot. For now, the focus here is on code completion, but Copilot Chat and its other features will likely […]
Xcode 16.1
Apple (downloads): Xcode 16.1 includes SDKs for iOS 18.1, iPadOS 18.1, tvOS 18.1, watchOS 11.1, macOS Sequoia 15.1, and visionOS 2.1. The Xcode 16.1 release supports on-device debugging in iOS 15 and later, tvOS 15 and later, watchOS 7 and later, and visionOS. Xcode 16.1 requires a Mac running macOS Sonoma 14.5 or later. I’m […]