My body is ugly [Re: Contextualizing keywords]
Michel Fortin
michel.fortin at michelf.com
Mon Aug 3 19:18:53 PDT 2009
On 2009-08-03 11:47:49 -0400, Don <nospam at nospam.com> said:
> I refuse to believe that the optimal solution to that problem involves
> the 'body' keyword.
Then would this do?
int test(int i)
in {
assert(i > 1);
}
out (z) {
assert(z < 0);
}
do {
return -i + 1;
}
Also, I wonder why we need braces everywhere in contracts. I'd like it
if I could write:
int test(int i)
in
assert(i > 1);
out (z)
assert(z < 0);
do
return -i + 1;
--
Michel Fortin
michel.fortin at michelf.com
http://michelf.com/
More information about the Digitalmars-d
mailing list