Header menu logo F# Compiler Guide

SynSimplePat Type

Represents a syntax tree for simple F# patterns

Union cases

Union case Description

Attrib(pat, attributes, range)

Full Usage: Attrib(pat, attributes, range)


An attributed simple pattern

pat : SynSimplePat
attributes : SynAttributes
range : range

Id(ident, altNameRefCell, isCompilerGenerated, isThisVal, isOptional, range)

Full Usage: Id(ident, altNameRefCell, isCompilerGenerated, isThisVal, isOptional, range)

 Indicates a simple pattern variable.

   Normally 'None' except for some compiler-generated variables in desugaring pattern matching.
   Pattern processing sets this reference for hidden variable introduced
   by desugaring pattern matching in arguments. The info indicates an
   alternative (compiler generated) identifier to be used because the
   name of the identifier is already bound.

 isCompilerGenerated: true if a compiler generated name
 isThisVal: true if 'this' variable in member
 isOptional: true if a '?' is in front of the name
ident : Ident
altNameRefCell : SynSimplePatAlternativeIdInfo ref option
isCompilerGenerated : bool
isThisVal : bool
isOptional : bool
range : range

Typed(pat, targetType, range)

Full Usage: Typed(pat, targetType, range)


A type annotated simple pattern

pat : SynSimplePat
targetType : SynType
range : range

Instance members

Instance member Description


Full Usage: this.Range

Returns: range
Returns: range

Type something to start searching.