Skip to content
Commit 2baf5a66 authored by Matt Wala's avatar Matt Wala
Browse files

Add a SymbolKindTable to DAGCode, make infer_kinds() a transformation

This adds a new attribute called *sym_kind_table* to DAGCode which is
a SymbolKindTable. The function *infer_kinds* is changed to be a
transformation that returns a modified DAGCode object with all symbol
kinds inferred.

Since DAGCode is immutable, SymbolKindTable is changed to be immutable
as well. The interface is changed to make SymbolKindTable free of side
effects. To maintain efficiency, the underlying dicts are replaced
with persistent dictionaries provided by pyrsistent.

This change also makes it an error when unification fails in
SymbolKindTable.set()

Closes #35 by providing an interface to supply kind information when
kind inference won't work
parent 1dacea79
Loading
Loading
Loading
Pipeline #20895 failed with stage
in 39 seconds