Skip to documentation
SLOP

tiny.chant.ParserNodeSurvey

Reference tiny.chant ParserNodeSurvey

Defined in tiny.chant.

The record stores the address and length of one lexed token slice, and a token limit equal to that length.

API (3)

Fields and members

Public fields and members.

No direct callersNo direct callstiny.chantParserNodeSurvey
Static calls · unresolved targets: unknown · external targets: unknown.

Source

Source: lib/chant/src/parse/state/storage.zig:25

zig
/// The record stores the address and length of one lexed token slice, and a/// token limit equal to that length. The record comes from `survey(tokens)` (a/// first pass counting what a second pass will store). The caller sizes parser/// node storage (a byte buffer the caller allocates) from its limit, and passes/// the record to parsing, so the storage can check that it parses the tokens it/// was sized for. Admission into parser node storage compares both with the/// slice it receives and returns `error.SurveyTokensMismatch` on any/// difference. The token slice stays at the same address and unchanged from the/// survey through parsing.pub const Survey = struct {    tokens_ptr: [*]const Token,    tokens_len: usize,    limits: Limits,};

Source: lib/chant/src/root.zig:83

zig
pub const ParserNodeSurvey = parse.Survey;

Also reachable as

parse.Survey, parse.state.Survey.

Audit

Definitions1
Public names3
Members3
Version26.7.0
Revisiondaab053ee433