math_spec.dimensions
Static dim-set checking — a type system whose type is a set of dim names.
Every node's dim set is computable before any data is bound, so this pass runs
at load on the resolved AST. The per-node rules are the "Dim algebra" table in
docs/reference/language/expressions.md; a constraint's two sides together
must equal its dims, and a where or a bound may not exceed the frame.
check_schema(schema, resolved)
#
Check every declaration's dim rules, on the trees resolved holds for schema.
| RAISES | DESCRIPTION |
|---|---|
DimensionError
|
On the first declaration that breaks one. |
Source code in src/math_spec/dimensions.py
dims_of(node, schema, context)
#
The dim set of a resolved expression, checking every rule on the way.
| RAISES | DESCRIPTION |
|---|---|
DimensionError
|
On the first rule broken. |