Lcalc.Monomorphize
val program :
Shared_ast.typed Ast.program ->
Shared_ast.typed Ast.program * Shared_ast.TypeIdent.t list
This function performs type monomorphization in a Catala program with two main actions:
TOption
for every occurence of the type.TArray
for every occurence of the type; each instance is a struct with a integer length
field and a content
field whose type still is TArray
.It also returns the new type ordering for the program.