style: apply swiftformat across the codebase#30
Conversation
|
Important Review skippedToo many files! This PR contains 151 files, which is 1 over the limit of 150. To get a review, narrow the scope: Upgrade to a paid plan to raise the limit. ⚙️ Run configurationConfiguration used: Path: .coderabbit.yml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (151)
You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
702a376 to
be82c62
Compare
Run swiftformat with the new project configuration. Notable mechanical changes include import sorting, attribute placement, multiline string indentation, trailing commas in multi-element lists, and Swift Testing test names converted to raw identifiers by swiftTestingTestCaseNames. Two manual accompaniments keep the build green: - CodingUserInfoKey.resilientDecodingErrorReporter is written as `: CodingUserInfoKey = .init(...)!` because the propertyTypes rule miscompiles the multiline `= CodingUserInfoKey(...)!` form into a tuple. - The @DefaultCodable test doubles are wrapped in `swiftformat:disable propertyTypes` regions, since an explicit type annotation breaks the wrapper's generic parameter inference. swift test passes in both debug (303) and release (295) configurations. Claude-Session: https://claude.ai/code/session_017kn3Hf2khxiFy1TqimTGx9
be82c62 to
23dbcef
Compare
What
Run
swiftformat .across the codebase (153 files) with the house-style configuration (2-space indent, 120-column limit). Notable mechanical changes:testable-bottom), attribute placement (prev-line), multiline string re-indentation, trailing commas in multi-element listsswiftTestingTestCaseNames(e.g.func testPolymorphicEnumValue()→func `polymorphic enum value`())The
.swiftformat/.swiftlint.ymlconfiguration files themselves are intentionally not part of this PR.Manual accompaniments (kept the build green)
CodingUserInfoKey.resilientDecodingErrorReporteris written as: CodingUserInfoKey = .init(...)!— thepropertyTypesrule miscompiles the multiline= CodingUserInfoKey(...)!form into a tuple (SwiftFormat 0.62.1 bug). The.initform is stable under re-runs.@DefaultCodabletest doubles are wrapped inswiftformat:disable propertyTypesregions — an explicit type annotation breaks the wrapper's generic parameter inference.Verification
swiftformat .is idempotent on the final tree.swift testpasses in debug (303) and release (295) configurations.Notes
mainafter it merges. Formatting only — no behavior changes beyond the two accompaniments above.https://claude.ai/code/session_017kn3Hf2khxiFy1TqimTGx9