KiwiCodec.RustlerGenerator.RustExpr (kiwi_codec v0.6.0)

Copy Markdown View Source

Rust expressions generated decoders read Kiwi values with, built as RustQ AST.

Each reads one value from the decoder in scope, with env for values that become terms.

Summary

Functions

Returns decoder.read_*(...)? for a primitive type, or nil for a schema definition.

Returns the decoder.read_*(...) call reading a primitive type, without ?.

Functions

primitive(type)

@spec primitive(String.t()) :: RustQ.Rust.AST.expr() | nil

Returns decoder.read_*(...)? for a primitive type, or nil for a schema definition.

read(type)

Returns the decoder.read_*(...) call reading a primitive type, without ?.