May 30, 2006 [Bug 167] New: .offsetof doesn't work when a struct/union/class is the target | ||||
---|---|---|---|---|
| ||||
http://d.puremagic.com/bugzilla/show_bug.cgi?id=167 Summary: .offsetof doesn't work when a struct/union/class is the target Product: D Version: 0.159 Platform: PC OS/Version: Linux Status: NEW Severity: normal Priority: P3 Component: DMD AssignedTo: bugzilla@digitalmars.com ReportedBy: h3r3tic@mat.uni.torun.pl struct o_O { int a; } union O_O { int a; } class O_o { int a; } struct Foo { int ok; o_O foo; O_O bar; O_o baz; } void main() { int o1 = Foo.ok.offsetof; // ok int o2 = Foo.foo.offsetof; // blah int o3 = Foo.bar.offsetof; // blah int o4 = Foo.baz.offsetof; // blah } -- |
Copyright © 1999-2021 by the D Language Foundation