mirror of
https://github.com/aljazceru/turso.git
synced 2026-02-23 08:55:40 +01:00
Remove Clone impl for Buffer and PageContent
This commit is contained in:
@@ -270,7 +270,6 @@ pub type BufferData = Pin<Vec<u8>>;
|
||||
|
||||
pub type BufferDropFn = Rc<dyn Fn(BufferData)>;
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct Buffer {
|
||||
data: ManuallyDrop<BufferData>,
|
||||
drop: BufferDropFn,
|
||||
|
||||
@@ -434,17 +434,6 @@ pub struct PageContent {
|
||||
pub overflow_cells: Vec<OverflowCell>,
|
||||
}
|
||||
|
||||
impl Clone for PageContent {
|
||||
fn clone(&self) -> Self {
|
||||
#[allow(clippy::arc_with_non_send_sync)]
|
||||
Self {
|
||||
offset: self.offset,
|
||||
buffer: Arc::new(RefCell::new((*self.buffer.borrow()).clone())),
|
||||
overflow_cells: self.overflow_cells.clone(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl PageContent {
|
||||
pub fn new(offset: usize, buffer: Arc<RefCell<Buffer>>) -> Self {
|
||||
Self {
|
||||
|
||||
Reference in New Issue
Block a user