diff --git a/src/main/scala/leon/codegen/CodeGeneration.scala b/src/main/scala/leon/codegen/CodeGeneration.scala index 3e4af03bd526ccf122a6d05f63f4872b9f69688a..4125eadddc4b3446d15cf5be6e9dc408c510fa4c 100644 --- a/src/main/scala/leon/codegen/CodeGeneration.scala +++ b/src/main/scala/leon/codegen/CodeGeneration.scala @@ -978,7 +978,7 @@ trait CodeGeneration { mkExpr(l, ch) mkExpr(r, ch) l.getType match { - case Int32Type => + case Int32Type | CharType => ch << If_ICmpLt(thenn) << Goto(elze) case IntegerType => ch << InvokeVirtual(BigIntClass, "lessThan", s"(L$BigIntClass;)Z") @@ -989,7 +989,7 @@ trait CodeGeneration { mkExpr(l, ch) mkExpr(r, ch) l.getType match { - case Int32Type => + case Int32Type | CharType => ch << If_ICmpGt(thenn) << Goto(elze) case IntegerType => ch << InvokeVirtual(BigIntClass, "greaterThan", s"(L$BigIntClass;)Z") @@ -1000,7 +1000,7 @@ trait CodeGeneration { mkExpr(l, ch) mkExpr(r, ch) l.getType match { - case Int32Type => + case Int32Type | CharType => ch << If_ICmpLe(thenn) << Goto(elze) case IntegerType => ch << InvokeVirtual(BigIntClass, "lessEquals", s"(L$BigIntClass;)Z") @@ -1011,7 +1011,7 @@ trait CodeGeneration { mkExpr(l, ch) mkExpr(r, ch) l.getType match { - case Int32Type => + case Int32Type | CharType => ch << If_ICmpGe(thenn) << Goto(elze) case IntegerType => ch << InvokeVirtual(BigIntClass, "greaterEquals", s"(L$BigIntClass;)Z")