Function |is_positive

std/ops/num::|is_positive


Usage

|is_positive<N>(value)

Generics

◻ N: Signed

Parameters

↳ value: N

Return

↴ bool


Tells if a value is positive.

Returns true for strictly positive integers, and false for 0 and negative ones.
ℹ️ For floating types (f32 and f64), NaN values gives false, +INFINITY and +0.0 gives true.