D - init property
I think something isn't right with the init property becuase when I used it
on a HANDLE (void*) like so: if(hfile == hfile.init) it would give me the
vague error:
void has no value
I didn't even know what that came from until I searched the dmd src and
found that error message in cast.c. To find the problem in my code, I
commented out parts and recompiled a few times. When I did hfile =
hfile.init it also gave me this error:
cannot implicitly convert void to void*
I found out it compiles fine with the windows.d that comes with DMD, I'm
using the one Andy Friesen posted awhile ago and all I changed in it was
having HANDLE be void* instead of int. So it might be a problem with
aliases? I did have a strange problem with aliases before. Something like
this:
struct tagFOO
{
int bla;
}
alias tagFOO FOO;
alias tagFOO* LPFOO;
In one case, using LPFOO thought it was a pointer to some other struct
whereas FOO* worked fine (I was adding some Windows code before I found that
nice windows.d from Andy Friesen).
Apr 27 2003








"Walter" <walter digitalmars.com>