Commit c6f5bb5f authored by Sapphie's avatar Sapphie
Browse files

Temporarily simplify halt representation

parent aa303d4e
......@@ -81,27 +81,28 @@ object CPSValueRepresenter extends (H.Tree => L.Tree) {
val untagUnitCont = mkeUntagCont("unit_untag", 2)
// If it's a unit, untag it, otherwise, immediately skip to halt
val unitCheckCont = mkeCheckCont("unit_check",
transformIf(L3.UnitP, Seq(v), untagUnitCont.name, haltCont))
// val unitCheckCont = mkeCheckCont("unit_check",
// transformIf(L3.UnitP, Seq(v), untagUnitCont.name, haltCont))
// If it's a boolean, untag it, otherwise check if it's a unit
val boolCheckCont = mkeCheckCont("bool_check",
transformIf(L3.BoolP, Seq(v), untagBoolCont.name, unitCheckCont.name))
// val boolCheckCont = mkeCheckCont("bool_check",
// transformIf(L3.BoolP, Seq(v), untagBoolCont.name, unitCheckCont.name))
// if it's a character, untag it, otherwise check if it's a boolean
val charCheckCont = mkeCheckCont("char_check",
transformIf(L3.CharP, Seq(v), untagCharCont.name, boolCheckCont.name))
//val charCheckCont = mkeCheckCont("char_check",
// transformIf(L3.CharP, Seq(v), untagCharCont.name, boolCheckCont.name))
//etc
val letCBody = transformIf(L3.IntP, Seq(v), untagIntCont.name, charCheckCont.name)
val letCBody = transformIf(L3.IntP, Seq(v), untagIntCont.name, haltCont)
val conts = Seq(untagIntCont,
untagCharCont,
untagBoolCont,
untagUnitCont,
unitCheckCont,
charCheckCont,
boolCheckCont)
// untagCharCont,
// untagBoolCont,
// untagUnitCont,
// unitCheckCont,
// charCheckCont,
// boolCheckCont
)
L.LetC(conts, letCBody)
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment