int nan
Michiel Helvensteijn
m.helvensteijn.remove at gmail.com
Sun Jun 28 10:28:01 PDT 2009
Ary Borenszweig wrote:
>> int i;
>> assert(foo() > 3);
>> for(int j = foo(); j > 3; j--) i = j;
>> auto k = i; // Compiles at the moment...
>>
>> Would C# swallow that?
>
> Of course not:
>
> int foo() {
> return rand() % 10;
> }
My mistake. For some reason I was assuming 'foo' was pure.
int i;
int j = foo();
assert(j > 3);
for(; j > 3; j--) i = j;
auto k = i;
Would C# allow this?
--
Michiel Helvensteijn
More information about the Digitalmars-d
mailing list