Comment #0 by bearophile_hugs — 2012-10-11T10:09:32Z
Problem found by Lubos Pintes:
http://forum.dlang.org/thread/[email protected]
enum Foo : void* {
a = null
}
void main() {
auto f = Foo.a;
}
DMD 2.061alpha gives:
temp.d(5): Error: no property 'a' for type 'void'
Comment #1 by andrej.mitrovich — 2012-11-27T15:58:45Z
Note that there's another separate and unrelated bug here, you can't compile this with -g.
D:\dev\code\d_code>dmd -g test.d
test.d(4): Error: Integer constant expression expected instead of null
test.d(4): Error: Integer constant expression expected instead of null
I'm not sure if this is filed yet.
Comment #2 by andrej.mitrovich — 2012-11-27T16:26:32Z
Comment #3 by bearophile_hugs — 2012-11-27T16:52:25Z
(In reply to comment #1)
> I'm not sure if this is filed yet.
I think that's already in Bugzilla (not filed by me).
Comment #4 by r.sagitario — 2012-11-27T22:33:14Z
(In reply to comment #1)
> Note that there's another separate and unrelated bug here, you can't compile
> this with -g.
>
> D:\dev\code\d_code>dmd -g test.d
> test.d(4): Error: Integer constant expression expected instead of null
> test.d(4): Error: Integer constant expression expected instead of null
>
> I'm not sure if this is filed yet.
This is issue 5168.
Comment #5 by github-bugzilla — 2012-12-02T17:20:19Z