Comment #0 by verylonglogin.reg — 2011-11-07T01:43:54Z
---
void main() {
static assert(is(typeof({
return int.init; // int, long, real, etc.
})));
int f() pure nothrow { assert(0); }
alias int T() pure nothrow;
static if(is(typeof(&f) DT == delegate)) {
static assert(is(DT* == T*)); // ok
// Error: static assert (is(pure nothrow int() == pure nothrow int())) is false
static assert(is(DT == T));
}
}
---
Comment #1 by clugdbug — 2011-11-07T03:21:28Z
I thought we got rid of those crazy function types. Seems that they've survived in alias declarations somehow.
The declaration of T shouldn't compile.
Comment #2 by k.hara.pg — 2011-11-07T03:33:51Z
Good reducing!
I found a function/delegate literal type inference bug.
I have done Phobos unit tests with my patch, and this resolves Phobos build breaking in Windows.
http://d.puremagic.com/test-results/test_data.ghtml?dataid=113170
Please wait the patch a while.