pub enum NumericKind {
Finite,
NaN,
PosInf,
NegInf,
}Expand description
A row-cell value, including SQL NULL. Float uses f64; NaN compares
non-equal to itself (PG behaviour) — PartialEq is derived so callers
must opt into NaN-aware comparison if they need stronger guarantees.
v7.37.42-arena Phase 1: parameterised on 'arena so heap-bearing
variants (Text/Json/Xml/Bytes/Vector/BitString.bytes) can borrow from
a per-query bump arena (Cow::Borrowed(&'arena ...)). Persistent /
catalog Values use Value<'static> (alias ValueOwned) with
Cow::Owned(...). Phase 1 keeps Range/Multirange recursive Box<Value>
at 'static (owned) — arena migration deferred to a later phase.
Array-of-OptionFinite is the
ordinary fixed-point case; the specials mirror PG’s 'NaN' / 'Infinity' /
'-Infinity'. Derived PartialEq gives NaN == NaN — correct for NUMERIC
(unlike float’s NaN ≠ NaN); the total order (-Inf < finite < +Inf < NaN)
lives in the comparison paths, not in Ord.
Variants§
Trait Implementations§
Source§impl Clone for NumericKind
impl Clone for NumericKind
Source§fn clone(&self) -> NumericKind
fn clone(&self) -> NumericKind
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more