http://d.puremagic.com/issues/show_bug.cgi?id=3934



--- Comment #6 from bearophile_h...@eml.cc 2010-07-25 07:01:22 PDT ---
Two more related cases:

This looks correct:

auto main() {
    return 0;
}

But dmd 2.047 prints:
test.d(1): Error: function D main must return int or void

----------------

The error message shows that foo() is not pure:
test.d(5): Error: pure function 'bar' cannot call impure function 'foo'


auto pure foo() {
    return 1;
}
pure void bar() {
    foo();
}
void main() {}


So it seems 'pure' is ignored if 'auto' is present.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to