Expand description
Evaluator: walks the crate::ast and produces a placed-primitive
Drawing using pic’s positioning semantics.
Model (Kernighan §3): a pen with a current position and current
direction walks the plane dropping primitives. Closed objects (box/circle/
ellipse/block) attach at the current point and advance by their extent;
open objects (line/arrow/move/spline/arc) trace from the current point in
the current direction. Labels, compass corners and ordinals
(last/nth) resolve against previously placed objects.
Approximations (documented; refined later): arc renders a default quarter
turn.
Structs§
- Eval
Error - An evaluation error.
infocarries the structured diagnostic when the failure site had one at hand (a deferred-parse error’s fullDiagnostic, or a place reference’s span); bindings surface it without re-deriving positions from the message. - Eval
Limits
Constants§
- DEFAULT_
MAX_ ANIMATION_ REPEAT - DEFAULT_
MAX_ ANIMATION_ SECONDS - DEFAULT_
MAX_ LOOP_ ITERATIONS - DEFAULT_
MAX_ SHAPES
Functions§
- eval
- Evaluate a parsed picture into a
Drawing. - eval_
with_ limits - Evaluate a parsed picture with host-provided resource limits.