LanguagePrimitives Module
Language primitives associated with the F# language
Nested modules
| Modules | Description |
|
For compiler use only |
|
|
The F# compiler emits calls to some of the functions in this module as part of the compiled form of some language constructs |
|
|
The F# compiler emits calls to some of the functions in this module as part of the compiled form of some language constructs |
|
|
The F# compiler emits calls to some of the functions in this module as part of the compiled form of some language constructs |
Functions and values
| Function or value |
Description
|
|
|
|
|
Full Usage:
DivideByInt x y
Parameters:
^T
-
The input value.
y : int
-
The input int.
Returns: ^T
The division result.
Modifiers: inline Type parameters: ^T (requires (static member DivideByInt : ^T * Microsoft.FSharp.Core.int -> ^T)) |
Divides a value by an integer.
|
Full Usage:
EnumOfValue value
Parameters:
'T
-
The input value.
Returns: 'Enum
The value as an enumeration.
Modifiers: inline Type parameters: 'T, 'Enum (requires enum<'T>) |
Build an enum value from an underlying value
|
Full Usage:
EnumToValue enum
Parameters:
'Enum
-
The input enum.
Returns: 'T
The enumeration as a value.
Modifiers: inline Type parameters: 'Enum, 'T (requires enum<'T>) |
Get the underlying value for an enum value
|
Full Usage:
FastGenericComparer
Returns: IComparer<'T>
Modifiers: inline Type parameters: 'T (requires comparison) |
Make an F# comparer object for the given type
|
Full Usage:
FastGenericEqualityComparer
Returns: IEqualityComparer<'T>
Modifiers: inline Type parameters: 'T (requires equality) |
Make an F# hash/equality object for the given type
|
Full Usage:
FastLimitedGenericEqualityComparer limit
Parameters:
int
-
The input limit on the number of nodes.
Returns: IEqualityComparer<'T>
System.Collections.Generic.IEqualityComparer<'T>
Modifiers: inline Type parameters: 'T (requires equality) |
Make an F# hash/equality object for the given type using node-limited hashing when hashing F# records, lists and union types.
|
|
|
|
|
|
A static F# comparer object
|
Full Usage:
GenericComparison e1 e2
Parameters:
'T
-
The first value.
e2 : 'T
-
The second value.
Returns: int
The result of the comparison.
Modifiers: inline Type parameters: 'T (requires comparison) |
Compare two values
|
|
|
Full Usage:
GenericEquality e1 e2
Parameters:
'T
-
The first value.
e2 : 'T
-
The second value.
Returns: bool
The result of the comparison.
Modifiers: inline Type parameters: 'T (requires equality) |
Compare two values for equality using partial equivalence relation semantics ([nan] <> [nan])
|
|
Return an F# comparer object suitable for hashing and equality. This hashing behaviour of the returned comparer is not limited by an overall node count when hashing F# records, lists and union types.
|
Full Usage:
GenericEqualityER e1 e2
Parameters:
'T
-
The first value.
e2 : 'T
-
The second value.
Returns: bool
The result of the comparison.
Modifiers: inline Type parameters: 'T (requires equality) |
Compare two values for equality using equivalence relation semantics ([nan] = [nan])
|
|
Return an F# comparer object suitable for hashing and equality. This hashing behaviour of the returned comparer is not limited by an overall node count when hashing F# records, lists and union types. This equality comparer has equivalence relation semantics ([nan] = [nan]).
|
Full Usage:
GenericEqualityWithComparer comp e1 e2
Parameters:
IEqualityComparer
-
e1 : 'T
-
The first value.
e2 : 'T
-
The second value.
Returns: bool
The result of the comparison.
Modifiers: inline Type parameters: 'T (requires equality) |
Compare two values for equality
|
Full Usage:
GenericGreaterOrEqual e1 e2
Parameters:
'T
-
The first value.
e2 : 'T
-
The second value.
Returns: bool
The result of the comparison.
Modifiers: inline Type parameters: 'T (requires comparison) |
Compare two values
|
Full Usage:
GenericGreaterThan e1 e2
Parameters:
'T
-
The first value.
e2 : 'T
-
The second value.
Returns: bool
The result of the comparison.
Modifiers: inline Type parameters: 'T (requires comparison) |
Compare two values
|
Full Usage:
GenericHash obj
Parameters:
'T
-
The input object.
Returns: int
The hashed value.
Modifiers: inline Type parameters: 'T |
Hash a value according to its structure. This hash is not limited by an overall node count when hashing F# records, lists and union types.
|
Full Usage:
GenericHashWithComparer comparer obj
Parameters:
IEqualityComparer
-
The comparison function.
obj : 'T
-
The input object.
Returns: int
The hashed value.
Modifiers: inline Type parameters: 'T |
Recursively hash a part of a value according to its structure.
|
Full Usage:
GenericLessOrEqual e1 e2
Parameters:
'T
-
The first value.
e2 : 'T
-
The second value.
Returns: bool
The result of the comparison.
Modifiers: inline Type parameters: 'T (requires comparison) |
Compare two values
|
Full Usage:
GenericLessThan e1 e2
Parameters:
'T
-
The first value.
e2 : 'T
-
The second value.
Returns: bool
The result of the comparison.
Modifiers: inline Type parameters: 'T (requires comparison) |
Compare two values
|
|
|
Full Usage:
GenericMaximum e1 e2
Parameters:
'T
-
The first value.
e2 : 'T
-
The second value.
Returns: 'T
The maximum value.
Modifiers: inline Type parameters: 'T (requires comparison) |
Take the maximum of two values structurally according to the order given by GenericComparison
|
Full Usage:
GenericMinimum e1 e2
Parameters:
'T
-
The first value.
e2 : 'T
-
The second value.
Returns: 'T
The minimum value.
Modifiers: inline Type parameters: 'T (requires comparison) |
Take the minimum of two values structurally according to the order given by GenericComparison
|
Full Usage:
GenericOne
Returns: ^T
Modifiers: inline Type parameters: ^T (requires (static member get_One : -> ^T)) |
Resolves to the value 'one' for any primitive numeric type or any type with a static member called 'One'
|
Full Usage:
GenericZero
Returns: ^T
Modifiers: inline Type parameters: ^T (requires (static member get_Zero : -> ^T)) |
Resolves to the zero value for any primitive numeric type or any type with a static member called 'Zero'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Full Usage:
PhysicalEquality e1 e2
Parameters:
'T
-
The first value.
e2 : 'T
-
The second value.
Returns: bool
The result of the comparison.
Modifiers: inline Type parameters: 'T (requires not struct) |
Reference/physical equality. True if the inputs are reference-equal, false otherwise.
|
Full Usage:
PhysicalHash obj
Parameters:
'T
-
The input object.
Returns: int
The hashed value.
Modifiers: inline Type parameters: 'T (requires not struct) |
The physical hash. Hashes on the object identity.
|
|
|
|
|
|
|
|
|
Full Usage:
UIntPtrWithMeasure input
Parameters:
unativeint
-
The input unativeint.
Returns: unativeint<'Measure>
The unativeint with units-of-measure.
Modifiers: inline Type parameters: 'Measure |
Creates a unativeint value with units-of-measure
|
FSharp.Core