Releases: JuliaEditorSupport/JuliaFormatter.jl
Release list
v2.8.3
v2.8.2
JuliaFormatter v2.8.2
Fixed a bug where JuliaFormatter would insert newlines around a parenthesised caller in a function definition, causing the function to be parsed differently on Julia 1.12.
This is probably a Julia bug and not really JuliaFormatter's fault, but this patch works around it. (#1114, #1117)
Merged pull requests:
- Fix parenthesised caller bug (#1117) (@penelopeysm)
Closed issues:
- callable struct idempotence (#1114)
v2.8.1
JuliaFormatter v2.8.1
Fixed a bug causing line comments inside array literals to be dropped or otherwise cause non-idempotent formatting. (#1113, #1115, #1116)
Merged pull requests:
- Fix changelog (#1111) (@penelopeysm)
- Add more regression repos for DefaultStyle (#1112) (@penelopeysm)
- fix comments in array literals (#1115) (@penelopeysm)
Closed issues:
v2.8.0
JuliaFormatter v2.8.0
Fixed a bug causing lack of idempotence in typed comprehension expressions (i.e., things like T[expr for x in y]). (#1105, #1106)
Fixed a bug causing lack of idempotence when using surround_whereop_typeparameters=true (when the { and } were inserted, line breaks were not initially being allowed next to them, but would be allowed on the second parse). (#1107, #1106)
Fixed a bug causing lack of idempotence when in / = / ∈ were being converted inside a for-expression (the change in character length was not being accounted for in nesting decisions). (#1108, #1106)
Added a new formatting option, v2_stable_multiline_strings, which aims to guarantee formatting idempotence with multiline strings.
By default this option is not enabled as it will lead to some changes in the formatting of expressions containing multiline strings: you must opt into it.
Please see the documentation for more information. (#1109, #1110)
Merged pull requests:
- Fix idempotence bugs (#1106) (@penelopeysm)
- Fix multiline string idempotence bug (#1110) (@penelopeysm)
Closed issues:
v2.7.0
JuliaFormatter v2.7.0
Improved usage messages for the jlfmt command-line tool. (#1098)
Added the ability to format only specific lines of a file, either via the --lines option to jlfmt, or the lines keyword argument to format_text(). (#191, #1099, #1100)
Merged pull requests:
- app: Clarify jlfmt check guidance for multiple inputs (#1098) (@aviatesk)
- Support line-range formatting (
lineskwarg andjlfmt --lines) (#1100) (@aviatesk) - Declare docs and test as Pkg workspace projects (#1101) (@aviatesk)
Closed issues:
v2.6.15
JuliaFormatter v2.6.15
Fixed a bug where the combination of always_use_return and short_circuit_to_if would silently change the meaning of a programme. (#887, #1096)
Fixed a bug where short_circuit_to_if would fire inside the condition of a while loop, leading to invalid code. (#940, #1096)
Fixed a bug where if an entire file was sandwiched in #! format: off and #! format: on comments but contained additional whitespace/comments after the final #! format: on, the file's contents would be deleted. (#949, #1097)
Merged pull requests:
- Fix high severity
short_circuit_to_ifbugs (#1096) (@penelopeysm) - Fix format:on end of file bug (#1097) (@penelopeysm)
Closed issues:
v2.6.14
JuliaFormatter v2.6.14
Fixed a bug where placing a comment after a do keyword would cause non-idempotent formatting. (#1088, #1090)
Fixed lack of idempotence on generator expressions that contained block elements. (#897, #941, #1048, #1092)
Fixed a bug where formatting generator expressions that contained block elements with SciMLStyle would cause the for ... in ... to be glued to the end of the block, leading to unparseable code. (#1092)
Merged pull requests:
- Fix idempotence bug with do-block (#1090) (@penelopeysm)
- Docs (#1092) (@penelopeysm)
- Idempotence on generator expressions + BlueStyle chained ternary->if (#1093) (@penelopeysm)
- Debump patch (#1095) (@penelopeysm)
Closed issues:
v2.6.13
JuliaFormatter v2.6.13
Fixed a bug where JuliaFormatter would insert trailing commas after expressions that had macros or global keywords, leading to syntactically invalid Julia code. (#1017, #1086)
Merged pull requests:
- Fix cases where trailing comma should not be added (#1086) (@penelopeysm)
Closed issues:
v2.6.12
JuliaFormatter v2.6.12
Fixed a bug where ;;\n separators in rows of array literals were being converted to ;;, leading to invalid Julia code. (#1080, #1083)
Fixed a bug where comments inside array literals caused non-idempotent formatting with SciML and YAS styles. (#1082, #1083)
Merged pull requests:
- Fix some array bugs (and uncover more, and fix them too) (#1083) (@penelopeysm)
- patch and changelog (#1085) (@penelopeysm)
Closed issues:
- HTML inside Markdown not formatted correctly, leads to errors. (#666)
- Enhancement: Allow selective longer lines (#697)
remove_extra_newlines=truesometimes removes newlines that are not extra (#705)- Inconsistent line breaks with binary operators (#739)
- Make default nesting in SciML style more readable (#741)
- Type assertion error when formatting a file (#742)
- Feature request: maintain absent whitespace around binary operations (#780)
- Long and cumbersome unfolding of arrays (#787)
- Parameter to disable margin constraints? (#836)
- Yet another ncat/hcat bug (#1080)
- SciMLStyle fails with comments in array literal (#1082)
v2.6.11
JuliaFormatter v2.6.11
Fixed a bug where linebreaks were not preserved in the middle of a chain of binary operators when a comment was present (e.g. a + # comment\n b + c), causing any part of the chain after the comment to be lost. (#1076, #1077)
Fixed a bug where formatting <:(X, Y), <:(args...), or the equivalent with >: would fail. (#1078, #1079, #1077)
Merged pull requests:
- Fix more failures on formatting JuliaLang/julia (#1077) (@penelopeysm)
Closed issues: