We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
Clone
PageTable
1 parent aab7181 commit eeb7b63Copy full SHA for eeb7b63
src/structures/paging/page_table.rs
@@ -177,8 +177,12 @@ const ENTRY_COUNT: usize = 512;
177
///
178
/// This struct implements the `Index` and `IndexMut` traits, so the entries can be accessed
179
/// through index operations. For example, `page_table[15]` returns the 15th page table entry.
180
+///
181
+/// Note that while this type implements [`Clone`], the users must be careful not to introduce
182
+/// mutable aliasing by using the cloned page tables.
183
#[repr(align(4096))]
184
#[repr(C)]
185
+#[derive(Clone)]
186
pub struct PageTable {
187
entries: [PageTableEntry; ENTRY_COUNT],
188
}
0 commit comments