2038 Commits

Author SHA1 Message Date
Nick Lockwood de413fec1d Update for 0.58.3 release 2025-10-04 14:33:11 +01:00
Nick Lockwood a605b2854c Fix unexpected wrapping of closing paren 2025-10-04 14:26:21 +01:00
Nick Lockwood aeb0c07511 Fix parsing multiline string delimiter followed by white space 2025-10-04 14:26:21 +01:00
Nick Lockwood e679a471d7 Fix redundantInit handling of Foo.self as Bar.Type expressions 2025-10-04 11:38:48 +01:00
Nick Lockwood fa65ed6e64 Improve acronyms rule 2025-10-04 11:10:28 +01:00
Nick Lockwood 60cd0f8ab6 Fix bug with parsing empty property accessors 2025-10-04 09:25:55 +01:00
Nick Lockwood a7f33d627a Fix parens orphaned by redundantInit rule 2025-10-04 08:46:46 +01:00
Nick Lockwood bc97082d59 Refactor spaceAroundParens rule 2025-10-04 08:46:46 +01:00
Nick Lockwood 3e4dc4e575 Fix of in fixed-size arrays being mistaken for an identifier 2025-10-04 08:46:46 +01:00
Nick Lockwood 6ea6ae64c7 Add new rules to project .swiftformat file 2025-10-04 08:46:46 +01:00
Nick Lockwood 83e5f6aa58 Add unknown-rules option 2025-10-04 08:46:46 +01:00
Cal Stephens 0fa1f65333 Prepare for 0.58.2 release 2025-09-29 08:36:54 -07:00
Cal Stephens a3dd82ca0d Fix issue where modifiersOrder rule confused async effect for async modifier (#2237) 2025-09-29 08:28:36 -07:00
Nick Lockwood aa41dc7544 Fix bug with test helper functions mistaken for tests 2025-09-29 08:28:36 -07:00
Cal Stephens 08c51ce965 Update redundantInit rule to apply to function calls with single trailing closure argument (#2232) 2025-09-29 08:28:36 -07:00
Cal Stephens ccd88da328 Prepare for 0.58.1 release 2025-09-24 08:43:58 -07:00
Cal Stephens 133775bae1 Update redundantLet rule to handle #Preview macro (#2231) 2025-09-24 08:43:58 -07:00
Cal Stephens 0b5ab901ea Fix issue where .swift-version file was ignored if not also using config file (#2230) 2025-09-24 08:43:58 -07:00
Cal Stephens 23da5808d3 Fix issue where wrapAttributes rule would unexpectedly wrap async effect (#2229) 2025-09-24 08:43:58 -07:00
Cal Stephens 3aeb711d77 Fix bug where acronyms rule would incorrectly always capitalize potentially matching acronyms one letter before end of identifier (#2226) 2025-09-24 08:43:58 -07:00
Cal Stephens d3cfc9df66 Fix issue where redundantAsync ignored await keyword in string interpolation (#2225) 2025-09-24 08:43:58 -07:00
Cal Stephens 1c1d501068 Improve trailingClosures support for multiple trailing closures, fix bug where trailing closures could be applied to ineligible function calls (#2224) 2025-09-24 08:43:58 -07:00
Cal Stephens 9264bf3825 Fix issue where async effect could be confused for async modifier, breaking docCommentsBeforeModifiers rule in protocol body with async functions (#2220) 2025-09-24 08:43:58 -07:00
Cal Stephens 599dd01c5f Prepare for 0.58.0 release 2025-09-22 19:13:36 -07:00
Cal Stephens 51b6027154 Fix parseDeclarations parsing bug (#2214) 2025-09-22 19:13:36 -07:00
Cal Stephens cd09163b42 Handle Swift 6.2 bug where trailing commas are not allowed in closure literal tuple return types (#2213) 2025-09-22 19:13:36 -07:00
Cal Stephens b27e7c59e0 Handle bug where Swift 6.2 doesn't allow trailing commas in tuples within generic types 2025-09-22 19:13:36 -07:00
Cal Stephens 02e458209a Update trailingCommas rule to support bug fixes in Swift 6.2 2025-09-22 19:13:36 -07:00
Cal Stephens fe0dd073ec Update singlePropertyPerLine to preserve async let declarations (#2210) 2025-09-22 19:13:36 -07:00
Cal Stephens ebdc24c4a5 Improve support for XCTAssertEqual and XCTAssertNil in noForceUnwrapInTests (#2208) 2025-09-22 19:13:36 -07:00
Cal Stephens 9fbd4f0909 Add redundantAsync rule (#2207) 2025-09-22 19:13:36 -07:00
Cal Stephens cd87505ae5 Add redundantThrows rule (#2206) 2025-09-22 19:13:36 -07:00
Cal Stephens 0c45b4b4c3 Don't apply noForceTryInTests if function has a return type 2025-09-22 19:13:36 -07:00
Cal Stephens 5e82ae3ad6 Rename throwingTests rule to noForceTryInTests 2025-09-22 19:13:36 -07:00
Cal Stephens 703593f551 Add noForceUnwrapInTests rule (#2204) 2025-09-22 19:13:36 -07:00
Matt Czech 999ff9ec5d Fix blankLinesAroundMark not ignoring trailing comments at start of scope (#2203) 2025-09-22 19:13:36 -07:00
Cal Stephens 179fcae759 Fix bug where --type-body-marks remove wouldn't be respected on declarations with expected mark comment (#2200) 2025-09-22 19:13:36 -07:00
Cal Stephens fbbe980923 Add preferFinalClasses rule (#2196) 2025-09-22 19:13:36 -07:00
Cal Stephens d1e430c6a0 Add --default-test-suite-attributes option to preferSwiftTesting rule (#2192) 2025-09-22 19:13:36 -07:00
Cal Stephens d76ee377cf Fix bug where markTypes rule wouldn't add marks after extensions (#2191) 2025-09-22 19:13:36 -07:00
Cal Stephens 23e43f7ee4 Update trailingClosures rule to support multiple trailing closures (#2190) 2025-09-22 19:13:36 -07:00
Cal Stephens 8fdb655ddc Update propertyTypes rule to support Set literal initialization, in addition to arrays and dictionaries (#2189) 2025-09-22 19:13:36 -07:00
Nick Lockwood 035ce340d4 Make trailingCommas removal more strict 2025-09-22 19:13:36 -07:00
Nick Lockwood b829018a8e Add additional trailingCommas tests 2025-09-22 19:13:36 -07:00
Nick Lockwood 56184fab24 Fix trailingCommas logic for init declarations 2025-09-22 19:13:36 -07:00
Cal Stephens 5e7882baa8 Improve type-related helpers by adding TypeName type (#2187) 2025-09-22 19:13:36 -07:00
via-guy 33f7a6a108 Update propertyTypes rule support array and dictionary literals (#2185)
Co-authored-by: Cal Stephens <cal@calstephens.tech>
2025-09-22 19:13:36 -07:00
Cal Stephens f163a36821 Dont treat parens after a keyword as a function call 2025-09-22 19:13:36 -07:00
Cal Stephens 832e06822d Add option to disallow partial wrapping of functions and collections (#2186) 2025-09-22 19:13:36 -07:00
Cal Stephens cb97a7e224 Update trailingClosures and trailingCommas rules to support optional function calls (#2184) 2025-09-22 19:13:36 -07:00