def block.entry

yaml-for-bend@0.1.1.0 · scan.bend:1368

import yaml-for-bend@0.1.1.0/scan.bend as Scan
import Base
import yaml-for-bend@0.1.1.0/token.bend as T

1368# "- ": a block sequence's entry, which may open the sequence.
1369def block.entry(+st: Sc) -> Step:
1370  when(Step, sc.in_flow(st), u => block.entry.rest(st),
1371    u => when(Step, sc.tab(st), u => fail(st, "found a tab character that violates indentation", sc.at(st)),
1372    u => when(Step, sc.allowed(st), u => block.entry.rest(roll(st, sc.col(st), None{}, T.BSeqStart{}, sc.at(st))),
1373      u => fail(st, "block sequence entries are not allowed in this context", sc.at(st)))))

Uses (13)

Used by (1)