This uses the deprecated `strcmp` interface on Windows, which requires
the C library to be imported. Add the missing import to allow building
on Windows.
This allows the user to call those methods with an Array, or any other collection at hand (including lazy ones)
This change makes `return coalesce(columns.lazy.map { $0.name })` iterate lazily. Before this commit, `map` was returning a non-lazy Array.
ChatGPT remarks:
# Overview Section:
The phrase "GRDB optimally schedules those database access closures, in the best interest of the application" is vague and could benefit from more detail on how the scheduling optimizes for concurrency.
# Concurrency Warnings in Swift 6:
"We will address these issues, and provide general guidance in the following sections." This sentence suggests that detailed solutions will be discussed, but it is unclear how each error is related to the following section titles. A more specific reference to which section will cover what would help orient the reader.
# Non-Sendable Record Types Section:
The FAQ format is useful, but it could overwhelm the reader. Breaking up the FAQ into subsections with more concise answers or reordering it based on common issues could improve readability.
# Shorthand Closure Notation Section:
The explanation of why shorthand notation leads to warnings is somewhat technical. It may be helpful to clarify what "may introduce data races" means in practical terms for less experienced developers.
# Choosing Between Synchronous and Asynchronous Database Access:
The section recommends using asynchronous access but leaves open-ended guidance like "this may slow down other tasks". Adding a more concrete explanation of how to balance performance between synchronous and asynchronous approaches would benefit developers.
# General Clarification on Sendable:
Throughout the document, Sendable is mentioned frequently, but less-experienced developers might not fully understand why it matters. A short section or footnote on what Sendable is and why it’s important in Swift 6 concurrency might help provide context for readers unfamiliar with the concept.