-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Generating code that will not compile #46
Comments
You mean because |
Indeed. removal of the buffer and u flattens the name space and creates a conflict over the name data that wasn't there before. Also __u32 and __u8 are not being converted to their D forms. |
What are |
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Jun 28, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Jul 6, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Jul 26, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Jul 27, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Jul 27, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Jul 27, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Jul 27, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Jul 27, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Aug 1, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Aug 3, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Aug 6, 2016
ciechowoj
added a commit
to ciechowoj/dstep
that referenced
this issue
Aug 6, 2016
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is a one off case but…
The C code:
struct dtv_property {
*u32 cmd;
__u32 reserved[3];
union {
__u32 data;
struct dtv_fe_stats st;
struct {
__u8 data[32];
__u32 len;
__u32 reserved1[3];
void reserved2;
} buffer;
} u;
int result;
} __attribute ((packed));
results in the D code:
struct dtv_property
{
__u32 cmd;
__u32[3] reserved;
union
{
__u32 data;
struct dtv_fe_stats
{
__u8 len;
dtv_stats[4] stat;
}
dtv_fe_stats st;
struct
{
__u8[32] data;
__u32 len;
__u32[3] reserved1;
void* reserved2;
}
}
int result;
}
which is compile error not only because of the __u32 and __u8 types, but because of the field data in the anonymous struct.
I do not have any answers, but I think this marker for the problems needs to be put on record.
The text was updated successfully, but these errors were encountered: