Heptagon's C backend generates invalid struct equality tests
Consider the code below, which is perfectly valid.
type color = { red : int; green : int; blue : int }
fun same_color(a, b : color) returns (same : bool)
let
same = a = b;
tel
The C backend compiles the equality test to the ==
operator, which does not work on structs (due to alignment reasons), hence the generated code does not compile.