Skip to main content

Module variant

Module variant 

Source

Structsยง

VariantRef
Borrowed value of the variant type.
VariantVal
Owned value of the variant type.

Enumsยง

PathToken ๐Ÿ”’

Constantsยง

CANONICAL_NAN_F32 ๐Ÿ”’
CANONICAL_NAN_F64 ๐Ÿ”’
METADATA_LEN_SIZE ๐Ÿ”’

Functionsยง

append_datum_value ๐Ÿ”’
append_decimal ๐Ÿ”’
append_float64 ๐Ÿ”’
append_json_value ๐Ÿ”’
append_struct ๐Ÿ”’
append_variant_value ๐Ÿ”’
Re-encodes a variant value with the canonical builder, normalizing floats to their canonical bit patterns.
canonical_builder ๐Ÿ”’
collect_datum_field_names ๐Ÿ”’
collect_json_field_names ๐Ÿ”’
collect_variant_field_names ๐Ÿ”’
collect_variant_field_names_inner ๐Ÿ”’
Collects object field names for the canonical dictionary.
contains_non_finite_float ๐Ÿ”’
Returns whether the variant contains a non-finite float. Read errors also count so that the lossy path, which reports them, is taken.
expect_serialized_value ๐Ÿ”’
jsonb_to_json_value ๐Ÿ”’
Parses a jsonb value through its text form. The round trip is deliberate: serde_jsonโ€™s parser enforces a nesting limit, while walking jsonbb directly would recurse without a bound.
non_finite_to_json ๐Ÿ”’
normalize_double ๐Ÿ”’
See normalize_float.
normalize_float ๐Ÿ”’
Normalizes a float to its canonical bit pattern: a single NaN representation and -0.0 collapsed to +0.0.
parse_path ๐Ÿ”’
reject_duplicate_field ๐Ÿ”’
Variant objects require unique field names, but RisingWave struct types allow duplicates. Callers iterate fields in name order, so comparing against the previous name suffices.
split_serialized_value ๐Ÿ”’
variant_to_json_value_lossy ๐Ÿ”’
Converts a variant to a serde_json::Value, rendering non-finite floats as the strings "NaN" / "Infinity" / "-Infinity", following to_jsonb on float types.