SSA transform bug!
Try this:
int foo (int i)
{
a = with {
([0] <= [i] < [1]) :3;
}: genarray([1], 0);
b = with {
([0] <= [j] < [1]) :i;
}: genarray([1], 0);
return _sel_VxA_ ([0], b);
}
int main ()
{
return foo( 42);
}
when using sac2c 2.1.0-PuurGeluk-229-g32fe4 with -noprelude I get:
** 9: Preparing for code optimization ...
./crazy.sac:7:29: abort:
6. b = with {
7. ([0] <= [j] < [1]) :i;
↑
8. }: genarray([1], 0);
9. return _sel_VxA_ ([0], b);
Cannot infer type for i__SSA0_2 as it may be used without a previous definition.