Skip to content

Recursive structs #5

brson opened this Issue Apr 13, 2012 · 3 comments

3 participants

brson commented Apr 13, 2012

When C structs contain recursive pointers to their own type, bindgen outputs invalid Rust types. Probably the solution to this is to define C structs as Rust classes instead of records.

crabtw commented Apr 16, 2012

Currently recursive field in class would cause internal compiler error.

Now struct pointers are represented as *c_void, so recursive structs can be compiled.
However we have to do casts for these pointers.

Blei commented Oct 9, 2012

This seems to work as of master.

crabtw commented Oct 19, 2012

Fixed, thanks.

@crabtw crabtw closed this Oct 19, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.