[Home] Module Microsoft.FSharp.Core.Enum


Simple operations to convert between .NET enuemration types and integers

Deprecated Values

ValueDescription
[<Obsolete
  ("Use the '|||' bitwise-or operator on enumeration values instead, e.g. 'e1 ||| e2 ||| e3'")>]
val combine : 'a list -> 'a when 'a :> Enum

Note: Use the '|||' bitwise-or operator on enumeration values instead, e.g. 'e1 ||| e2 ||| e3'

Combine enum values using 'logical or'. The relevant enumeration type is inferred from context.
[<Obsolete
  ("Use the 'enum' conversion function instead, e.g. 'enum(3)'. You may also need to add a type annotation to indicate the source enumeration type")>]
val of_int : int -> #Enum

Note: Use the 'enum' conversion function instead, e.g. 'enum(3)'. You may also need to add a type annotation to indicate the source enumeration type

Convert an integer to an enumeration value. The result type is inferred from context.
[<Obsolete
  ("Use the '&&&' bitwise-and operator on enumeration values instead, e.g. 'e1 &&& e2 <> enum 0'")>]
val test : 'a -> 'a -> bool when 'a :> Enum

Note: Use the '&&&' bitwise-and operator on enumeration values instead, e.g. 'e1 &&& e2 <> enum 0'

Test if an enumeration value has a particular flag set, using 'logical and'. The relevant enumeration type is inferred from context.
[<Obsolete
  ("Use the 'int' or 'int32' conversion function instead. You may also need to add a type annotation to indicate the source enumeration type")>]
val to_int : #Enum -> int

Note: Use the 'int' or 'int32' conversion function instead. You may also need to add a type annotation to indicate the source enumeration type

Convert an enumeration value to an integer. The argument type is inferred from context.

See Also

Microsoft.FSharp.Core


Documentation for assembly FSharp.Core, version 1.9.4.19, generated using F# version 1.9.4.19