by lanestp · 10y ago · 0 comments
The advantage of this is that it's much harder to screw up block terminations --- one thing I've done many times in C is when closing a chain of blocks with:
}
}
}
do_something();
}
}
is to miscount the braces and put do_something() in the wrong place. In Ada, that'd be: end if;
end;
end case;
do_something();
end loop;
end;
...which is far more meaningful.That said, its easy range types and discriminated unions make writing C-level code SO much nicer.