cell.rs 228 B

1234567891011
  1. #[repr(C)]
  2. pub struct MyStruct {
  3. number: std::cell::Cell<i32>,
  4. }
  5. pub struct NotReprC<T> { inner: T }
  6. pub type Foo = NotReprC<std::cell::RefCell<i32>>;
  7. #[no_mangle]
  8. pub extern "C" fn root(a: &Foo, with_cell: &MyStruct) {}