Builtin vs. hardcoded types #2163
Labels
needs test
Issues for which we should add a regression test
tech debt
Issues that document or involve technical debt
type: bug
Issues reporting bugs or unexpected/unwanted behavior
Milestone
Right now (since merging #2157) most of the assorted builtin types are declared in a table in the interpreter, but some appear as hardcoded special cases of TyCon in AST.hs. The latter are also reserved words in the lexer and parser.
Some of these special cases need to be special cases because they have special semantics (e.g.
Term
) and some of them are inherently hardcoded (e.g.Int
) but there are several there's probably no need to do anything special with and these should probably be moved to the builtins table.The obvious candidates are: AIG CFG JVMSpec LLVMSpec MIRSpec.
Relatedly, once other cleanup makes them less special and given suitable infrastructure to deal with them having kind * -> * instead of *, most of the monad types enumerated in Context in AST.hs won't need to be hardcoded either, although this is more ambitious.
Finally, it seems unlikely that any of the names of named types (even those like
Int
) actually need to be reserved words, and tidiness suggests that at least some of them shouldn't be.The text was updated successfully, but these errors were encountered: