aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/generate_rust_target.rs
diff options
context:
space:
mode:
authorMiguel Ojeda <[email protected]>2024-04-01 21:23:01 +0000
committerMiguel Ojeda <[email protected]>2024-05-05 17:22:25 +0000
commit7c81aa85eee536f36ad79339bbbc7528a49d30fe (patch)
treeeaeba2199283f7d4c84f96a20275932ae499c5f3 /scripts/generate_rust_target.rs
parentdocs: rust: extend abstraction and binding documentation (diff)
downloadkernel-7c81aa85eee536f36ad79339bbbc7528a49d30fe.tar.gz
kernel-7c81aa85eee536f36ad79339bbbc7528a49d30fe.zip
rust: sync: implement `Default` for `LockClassKey`
In the upcoming Rust 1.78.0, Clippy suggests to implement `Default` even when `new()` is `const`, since `Default::default()` may call `const` functions even if it is not `const` itself [1]: error: you should consider adding a `Default` implementation for `LockClassKey` --> rust/kernel/sync.rs:31:5 | 31 | / pub const fn new() -> Self { 32 | | Self(Opaque::uninit()) 33 | | } | |_____^ Thus implement it. Link: https://github.com/rust-lang/rust-clippy/pull/10903 [1] Reviewed-by: Benno Lossin <[email protected]> Reviewed-by: Alice Ryhl <[email protected]> Reviewed-by: Boqun Feng <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Miguel Ojeda <[email protected]>
Diffstat (limited to 'scripts/generate_rust_target.rs')
0 files changed, 0 insertions, 0 deletions