as(_:)
Attempts to load an instance of some BinaryFloatingPoint
type from this variant.
func `as`<Fraction>(_: Fraction.Type) -> Fraction? where Fraction : BinaryFloatingPoint
Returns
The closest value of T
to the payload of this variant if it matches double(_:)
, nil otherwise.