method Num

Documentation for method Num assembled from the following types:

role Numeric

From Numeric

(Numeric) method Num

method Num(Numeric:D: --> Num:D)

If this Numeric is equivalent to a Real, return that Real as a Num as accurately as is possible. Fail with X::Numeric::Real otherwise.

role Rational

From Rational

(Rational) method Num

Defined as:

method Num(Rational:D: --> Num:D)

Coerces the invocant to Num by dividing numerator by denominator. If denominator is 0, returns Inf, -Inf, or NaN, based on whether numerator is a positive number, negative number, or 0, respectively.

class NumStr

From NumStr

(NumStr) method Num

method Num

Returns the Num value of the NumStr.