Logo fantomas

Fantomas.Core Namespace

Type/Module Description

AssemblyVersionInformation

ASTTransformer

Async

CodeFormatter

CodeFormatterImpl

CodePrinter

Context

Continuation

DefineCombination

DefineParseException

Raised when one or more conditional compilation define combinations produce invalid syntax trees.

Defines

EndOfLineStyle

EventList

Mutable doubly-linked list of WriterEvents. Supports O(1) append, insert, remove, and truncation.

EventNode

A node in the mutable doubly-linked list of WriterEvents. We use [] instead of option for Prev/Next links because this is a hot path — every formatting operation appends nodes. Option would allocate a Some wrapper on every link assignment, adding GC pressure for no functional benefit. The null checks are contained within EventList's methods; callers work with non-null EventNode references returned by Append/InsertAfter/InsertBefore.

FormatConfig

FormatException

Raised when Fantomas encounters a problem during formatting.

FormatResult

InvariantViolationException

Raised when Fantomas reaches a state that its own model says is impossible, for example a chain whose parts do not fit the shape the transformer guarantees. Unlike the other exceptions here, this never indicates a problem with the code being formatted: it is a bug in Fantomas, or a change in how the F# parser groups expressions. Failing loudly is deliberate — the alternative is silently dropping parts of the source.

List

MultilineBracketStyle

MultilineFormatterType

MultipleDefineCombinations

Num

ParseException

Raised when the F# parser produces errors for source code without conditional directives.

Queue

Queue<'T>

append only collection optimized for quick append of block of data and query operations data - list of blocks in reverse order

RangeHelpers

RangePatterns

Selection

String

SyntaxOak

Trivia

UnionCase

Validation

ValidationResult

What Fantomas made of a piece of F# source when it was asked whether that source is valid. The verdict and the reason for it together, because a caller that has to tell somebody why cannot reconstruct it from a boolean, and asking twice would parse the source twice.

Version

WriterEvent

Represents a single event emitted during the code formatting process. The sequence of writer events captures how the formatter produces its output.

Type something to start searching.