Repository navigation
Releases
Releases · fsprojects/fantomas
November 3rd Release
8.1.1
Fixed
- Comment between the type name and the primary constructor is removed. #3569
Special thanks to @claude, @nojaf and @xperiandri!
October 21 Release
9.0.0-alpha-002
Changed
- Everything that changed in 8.1.0, the layout changes and fixes listed under that release below. v8.1.0
October 21st Release
8.1.0 Umbra - 21-10-2026
Changed
- Multiline tuple type after a cast or type annotation operator goes one level in. #3561
- Line comment lined up with the first element of its container stays with the elements. #3561
Fixed
- Parenthesized function type gets an extra indent level where no outer function type needs it. #3554
- Multiline tuple in the middle of a function type gives invalid code. #3556
- Parenthesized function type after an arrow gives invalid code with indent_size 2. #3557
- Long type test with :? gives invalid code. #3558
- Line comment after the opening parenthesis of a type moves and breaks the type. #3559
- Comment between a match pattern and its when guard gives invalid code. #3560
- Regression: Stroustrup bracket style in anonymous record type parameter is not respected. #3069
- Space inserted before final > in type parameter. #2860
October 15 Release
9.0.0-alpha-001
Changed
- Fantomas checks that its output keeps every
//and(* *)comment of the file. A format run searches its result for each of them, and does not write a result that is missing one, even when it is valid F#. The daemon that editors use refuses such output too, and output that is not valid F#, where it used to send both to the editor.fantomas doctorhas aCommentsstep that checks, more thoroughly than a format run can afford, that the result keeps every comment and directive of the file under every define combination, aParsestep that lists the define combinations the file is parsed under, and ends on aVerdict: what a format run would do with the file.CodeFormatter.FormatDocumentWithValidationsAsynctakes the checks to run asValidations, andFormatResulthas a new field,Issues, with what they found, so code that constructs aFormatResulthas to set it.DefineParseException.Combinationsholds the defines of each combination that failed, rather than their names. #1353 - On Linux x64, the
fantomastool is an executable compiled with Native AOT. It starts in milliseconds rather than first starting the .NET runtime. Thefantomaspackage only names the packages per platform:fantomas.linux-x64and, for Alpine,fantomas.linux-musl-x64hold the executable, and every other platform installsfantomas.any, the tool as it shipped before. #3171
Special thanks to @nojaf!
October 14th Release
October 14th Release
October 9th Release
8.0.8
Changed
- Update FCS to 'Add range of the when keyword to SynMatchClauseTrivia', commit 409c7a62ea193ec060e87ccad78636feeb0883f1 #3531
Fixed
- Comment after 'when' on its own line is lost. The syntax tree had no range for the
whenkeyword of a match clause, so a comment after it had no node on its line to attach to. The parser now records that range, and the comment stays after the keyword. #3521
Special thanks to @nojaf!
October 5th Release
8.0.7
Fixed
- Exception abbreviation loses its right-hand side. #3511
- Static optimization when ^T struct loses struct. #3514
- Static optimization loses the
andbetween its conditions, and reverses its conditions andwhenclauses. #3516 - static extern inside a type loses static. #3515
Special thanks to @nojaf!
October 1st Release
8.0.6
Changed
- Update FCS to 'Record the range of the
ofkeyword in SynUnionCaseTrivia', commit 5e9647f158fe282462aba57ed83ada910a91b90e #3502
Fixed
- Wrong change of comment's position. The syntax tree had no range for the
ofkeyword of a union case or exception, so a block comment after it, as inexception E of (*name*) string, was attached to the case name and printed in front ofof. The parser now records that range, and the comment stays after the keyword. #1959 - Cursor is lost when placed on
if,thenorelse ifkeywords. The cursor now keeps its place onif,elif,else if,then,match,match!andwith. #3387 - Cursor is lost when placed on the closing bracket of a multiline list or array in the cramped style. #3506
September 25th Release
8.0.5
Changed
- Improved formatting performance. Formatting the source files of dotnet/fsharp allocates around 40% less memory and is roughly 1.4 times faster than
8.0.4, depending on hardware. The fields ofWriterEvent, returned byCodeFormatter.GetWriterEventsAsync, are renamed so that cases share them:textfor the strings,amountforIndentByandUnIndentBy,columnfor the indent and column cases, andnodeTypeandrangeforNodeEnd. #3499 - Update FCS to 'Record the range of the
exceptionin SynExceptionDefnRepr', commit 349d6aaf1e4685a72e43b7f4a0708205e4104b4c #3500
Fixed
- Comment between doc comment and exception keyword gets shifted. The syntax tree had no range for the
exceptionkeyword, so a comment between the XML doc or attributes and the keyword was placed in front of the exception name, after the keyword. The parser now records that range, and the comment stays in front of the keyword. #3483
Special thanks to @nojaf!