-
Notifications
You must be signed in to change notification settings - Fork 373
References in enum fields not supported? #485
Copy link
Copy link
Closed
Labels
Description
The docs say references are supported and translated to pointer types, but it does not say under which conditions that is the case. I am trying to expose the following tagged union:
#[repr(C)]
pub enum BoolOp<'a> {
Lit {value: bool},
And {left: &'a BoolOp<'a>, right: &'a BoolOp<'a>},
}This generates nothing in the exported header, not even an opaque type. The type only shows up in function parameters and return types.
I'd rather not replace the references with pointers and ruin the ergonomics on the Rust side of things. What should I do?
Reactions are currently unavailable