Skip to content

Bump Fantomas to 8.1.0 - #113

Merged
nojaf merged 2 commits into
mainfrom
fantomas-8
Oct 22, 2026
Merged

nojaf merged 2 commits into
mainfrom
fantomas-8

Conversation

@nojaf

@nojaf nojaf commented Oct 22, 2026 •

Copy link
Copy Markdown
Member

Bumps the Fantomas dotnet tool from 7.0.6 to 8.1.0. See the v8 upgrade guide.

Commits

  1. Bump Fantomas to 8.1.0
    • .config/dotnet-tools.json: version bump only.
    • .github/workflows/dotnet.yaml: the check-format job now installs the .NET 10 SDK (10.0.x), because the Fantomas 8 tool targets net10.0. The build, analyzer and pack jobs are unchanged.
    • hooks/pre-push: fantomas --check . becomes fantomas check .. Fantomas 8 adds check as a verb; the old flag still works, but this is the current spelling.
    • No .editorconfig changes: fantomas doctor reports no unknown or invalid settings, and fsharp_multiline_bracket_style = aligned (the new v8 default) was already set explicitly.
  2. Format with Fantomas 8.1.0: the formatting changes below, in 3 files. Nothing else.

Important

This repo only allows squash merges, so the format commit gets a new hash on merge. Its .git-blame-ignore-revs entry will be added in a follow-up PR once this one is squash-merged.

Formatting changes

There is one kind of change: the parenthesis of a method call is now tight when the thing being called is not a plain dotted name.

This repo sets fsharp_space_before_uppercase_invocation = true, which asks for a space before the parenthesis of a call such as Foo.Bar (). Fantomas 8 only applies that setting when the whole thing being called is a plain dotted name. A bracketed receiver like (f x).Method or a type application like x.Eval<'a> makes the call tight whatever the setting says. Plain dotted calls such as List.map (f) keep their space. This rule was agreed in the F# style guide discussion fsharp/fslang-design#648 and implemented in fsprojects/fantomas#3425.

Bracketed receiver (ShapeSifter/Reflection.fs, ShapeSifter.Test/TestExamples.fs):

-        let mi = (getMethodInfo e).GetGenericMethodDefinition ()
+        let mi = (getMethodInfo e).GetGenericMethodDefinition()

Type application (ShapeSifter/TypeParameterCrate.fs):

-            member __.Apply e = e.Eval<'a> ()
+            member __.Apply e = e.Eval<'a>()

Checks

dotnet fantomas check . and ./hooks/pre-push exit 0. dotnet build and dotnet test (41 tests) pass on the .NET 10.0.402 SDK.

@nojaf
nojaf requested review from a team as code owners October 22, 2026 06:50
@nojaf
nojaf merged commit a05afc1 into main Oct 22, 2026
13 checks passed
@nojaf
nojaf deleted the fantomas-8 branch October 22, 2026 07:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants