I tried 1.036 and had the same problem. I'm using the offsetof and sizeof in a few constants which I've defined at the beginning of the file so I tried moving to the end of the file and it is no longer in error. I read somewhere that you don't have to forward declare everything in D like you do in C and also dmd wasn't reporting any undefined type errors, just that the property didn't exist on it. Possible a bug?

On Sat, 08 Nov 2008 16:03:08 +1300, Jarrett Billingsley <[EMAIL PROTECTED]> wrote:

On Fri, Nov 7, 2008 at 8:59 PM, Tim M <[EMAIL PROTECTED]> wrote:
Did you find a sollution? I need to get the offset of a member of a struct so I can port a .h to a .di but dmd complains that the member doesn't exist
on the struct. I dont think anyone has ever tried the code at:
http://www.digitalmars.com/d/1.0/ctod.html#fieldoffset


Ehh, that code works with DMD 1.036, dude.  What compiler are you using?

Reply via email to