Skip to content

Releases: nicklockwood/SwiftFormat

0.48.17

18 Oct 08:31
Compare
Choose a tag to compare
  • Fixed bug where trailingCommas rule added comma to wrapped capture list with comment
  • Fixed indenting of closure with wrapped capture list
  • Fixed bug where redundantArguments rule stripped params used in pattern matching with inline let
  • Fixed bug where redundantArguments failed to detect shadowed param after tuple assignment
  • Fixed compilation error introduced when removing redundant parens with inner spaces

0.48.16

12 Oct 19:05
Compare
Choose a tag to compare
  • Fixed unexpected indentation of next line after a trailing closure
  • Fixed unexpected indentation of try expressions
  • Fixed bug where redundantInit could cause compilation failure
  • Fixed indenting of multiple trailing closures

0.48.15

08 Oct 23:17
Compare
Choose a tag to compare
  • Fixed false positives in unusedArgument rule when using try/await
  • Closing paren indent is now balanced for double-indented closures
  • Fixed bug where comment directive failed to disable redundantSelf rule
  • Fixed bug where redundantSelf exclusion list was not always applied
  • Fixed regression introduced in 0.48.5 affecting indenting of wrapped closure bodies
  • SwiftFormat directives are now recognized in the middle of a comment

0.48.14

07 Oct 06:33
Compare
Choose a tag to compare
  • Fixed some cases where function arguments were incorrectly treated as unused
  • Fixed incorrect removal of self for some shadowed variables when swift version is >= 5.4
  • Fixed indenting of wrapped method chains after a closing paren
  • Rules listed in swiftformat comment directives are now case-insensitive

0.48.13

05 Oct 07:08
Compare
Choose a tag to compare
  • Fixed bug where unusedArguments incorrectly marked shadowed parameters as unused
  • Fixed wrapped chained functions after an indented closing paren or square bracket
  • Fixed Mint install

0.48.12

03 Oct 13:50
Compare
Choose a tag to compare

The redundantSelf rule now removes self from shadowed variable references where permitted

  • Fixed bug where self was not correctly removed on the line following an assignment
  • Fixed some cases where self was incorrectly removed from @dynamicMemberLookup members
  • Fixed error raised where removing self caused ambiguity with global Swift functions
  • Function parameters with shadowed names are now correctly marked as unused
  • The --selfrequired option now applies to members, not just @autoclosure arguments
  • Fixed trailing comment placement when using wrapEnumCases rule
  • Fixed indenting of wrapped chained functions after a closing paren or square bracket
  • Fixed bug where some(Void) was converted to someVoid
  • Fixed potential range bounds crash in editDistance() function
  • Now uses automatic test discovery on Linux instead of XCTestManifests file

0.48.11

19 Jul 23:07
Compare
Choose a tag to compare
  • Fixed parsing error introduced in 0.48.10 involving inline closures inside conditional statements
  • Fixed bug where redundantSelf could potentially misidentify tuple labels as local variables

0.48.10

18 Jul 22:54
Compare
Choose a tag to compare
  • Fixed issue with redundantBackticks rule incorrectly removing required backticks around underscore
  • Fixed parsing error in redundantSelf with guard conditions containing inline closures

0.48.9

09 Jul 18:23
Compare
Choose a tag to compare
  • Fixed regression introduced in 0.48.7 where parens around prefix expressions were incorrectly removed

0.48.8

08 Jul 17:29
Compare
Choose a tag to compare
  • Fixed regression introduced in 0.48.7 where parens around operator literals were incorrectly removed