Skip to main content

Module ast

Module ast 

Source
Expand description

Abstract syntax tree for the Polydat DSL.

Structs§

Binding
A name-to-expression binding (per-cycle by default; const/shared/volatile modifier changes the lifecycle). Replaces the former CycleBinding and InitBinding AST variants — the surface unified to one shape name := expr (or (a, b, c) := expr for tuple destructuring), with the modifier driving runtime lifecycle.
BindingModifier
Set of wire modifiers carried by one binding declaration. Stored as a bitset under the hood; consumers use Self::has to test for individual modifiers and Self::insert / Self::from_iter to build instances.
CallExpr
A function call expression.
CursorDecl
A cursor declaration: cursor name = Cursor() [over partition_source]
ExternPort
An external input port declaration.
ForSource
What a for iterates: inline comprehension text, or the name of a bound producer wire.
ForStmt
A traversal statement: for <source> { statements }.
InputDecl
One per-cycle kernel input slot.
ModuleDef
A formal module definition with typed interface.
PolydatFile
A complete .polydat file.
TileDef
A tile definition: its header, its raw body, and the parsed template.
TileHole
A hole: an expression with an optional declared type, format spec, and raw flag.
TileOptions
Per-tile template options (SRD 114 §2.3): the hole delimiters, the directive sigil, and strictness.
TypedParam
A typed parameter in a module signature.

Enums§

Arg
A function argument: positional or named.
BinOpKind
Binary arithmetic operator kind.
Expr
An expression (right-hand side of a binding).
ForSourceKind
The parsed form of a for source.
Statement
A top-level statement.
TileBodyKind
How a tile body was written, so the printer can reproduce it.
TilePiece
One element of a parsed template.
WireModifier
One wire-coloring keyword. The single enum that names every modifier the grammar recognises before a binding name. Future modifiers are new variants here.