rust/zerocopy/benches/write_to_prefix_static_size.rs

Source file repositories/reference/linux-study-clean/rust/zerocopy/benches/write_to_prefix_static_size.rs

File Facts

System
Linux kernel
Corpus path
rust/zerocopy/benches/write_to_prefix_static_size.rs
Extension
.rs
Size
256 bytes
Lines
13
Domain
Rust Kernel Layer
Bucket
Rust API Membrane
Inferred role
Rust Kernel Layer: implementation source
Status
source implementation candidate

Why This File Exists

Rust-side wrappers and abstractions around kernel C APIs, ownership contracts, allocation, synchronization, and module integration.

Dependency Surface

Detected Declarations

Annotated Snippet

use zerocopy::*;

#[path = "formats/coco_static_size.rs"]
mod format;

#[unsafe(no_mangle)]
fn bench_write_to_prefix_static_size(
    source: &format::CocoPacket,
    destination: &mut [u8],
) -> Option<()> {
    source.write_to_prefix(destination).ok()
}

Annotation

Implementation Notes