YC.PrettyPrinter


StructuredFormat

Namespace: YC.PrettyPrinter

Functions and values

Function or valueDescription
( -- ) doc1 doc2
Signature: doc1:Doc -> doc2:Doc -> Doc

Join, possible break with indent = 1.

CompiledName: op_MinusMinus

( --- ) doc1 doc2
Signature: doc1:Doc -> doc2:Doc -> Doc

Join, possible break with indent = 2.

CompiledName: op_MinusMinusMinus

( @@ ) doc1 doc2
Signature: doc1:Doc -> doc2:Doc -> Doc

Join broken with ident = 0.

CompiledName: op_AtAt

( @@- ) doc1 doc2
Signature: doc1:Doc -> doc2:Doc -> Doc

Join broken with ident = 1.

CompiledName: op_AtAtMinus

( @@-- ) doc1 doc2
Signature: doc1:Doc -> doc2:Doc -> Doc

Join broken with ident = 2.

CompiledName: op_AtAtMinusMinus

( ^^ ) doc1 doc2
Signature: doc1:Doc -> doc2:Doc -> Doc

Join, unbreakable.

CompiledName: op_HatHat

( ++ ) doc1 doc2
Signature: doc1:Doc -> doc2:Doc -> Doc

Join, possible break with indent = 0.

CompiledName: op_PlusPlus

aboveL doc1 doc2
Signature: doc1:Doc -> doc2:Doc -> Doc

Layout two vertically.

aboveListL _arg1
Signature: _arg1:Doc list -> Doc

Layout list vertically.

braceL x
Signature: x:Doc -> Doc

Wrap braces around layout.

bracketL l
Signature: l:Doc -> Doc

Wrap round brackets around Layout.

commaListL x
Signature: x:Doc list -> Doc

Join layouts into a comma separated list.

emptyL
Signature: Doc

The empty doc.

isEmptyL d
Signature: d:'?7163 -> bool
Type parameters: '?7163

Is it the empty doc?

leftL s
Signature: s:string -> Doc

Stub for migration simplification.

listL xL xs
Signature: xL:('?7191 -> Doc) -> xs:'?7191 list -> Doc
Type parameters: '?7191

Layout like an F# list.

objL o
Signature: o:'?7165 -> Doc
Type parameters: '?7165

An uninterpreted leaf, to be interpreted into a string by the layout engine. This allows leaf layouts for numbers, strings and other atoms to be customized according to culture.

optionL xL _arg1
Signature: xL:('?7189 -> Doc) -> _arg1:'?7189 option -> Doc
Type parameters: '?7189

Layout like an F# option.

rightL s
Signature: s:string -> Doc

Stub for migration simplification.

semiListL x
Signature: x:Doc list -> Doc

Join layouts into a semi-colon separated list.

sepL s
Signature: s:string -> Doc

Stub for migration simplification.

sepListL x y
Signature: x:Doc -> y:Doc list -> Doc

Join layouts into a list separated using the given Layout.

spaceListL x
Signature: x:Doc list -> Doc

Join layouts into a space separated list.

squareBracketL x
Signature: x:Doc -> Doc

Wrap square brackets around layout.

tupleL xs
Signature: xs:Doc list -> Doc

Form tuple of layouts.

unfoldL itemL project z maxLength
Signature: itemL:('?7196 -> Doc) -> project:('?7197 -> ('?7196 * '?7197) option) -> z:'?7197 -> maxLength:int -> Doc list
Type parameters: '?7196, '?7197

For limitting layout of list-like sequences (lists,arrays,etc). Unfold a list of items using (project and z) making layout list via itemL. If reach maxLength (before exhausting) then truncate.

wordL s
Signature: s:string -> Doc

A string leaf.

Fork me on GitHub