]> git.hungrycats.org Git - linux/commit
rust: pin-init: internal: init: handle code blocks early
authorGary Guo <gary@garyguo.net>
Tue, 12 May 2026 12:09:49 +0000 (13:09 +0100)
committerGary Guo <gary@garyguo.net>
Mon, 18 May 2026 11:18:06 +0000 (12:18 +0100)
commitdf1827babd665ea7039383dbc5c671b66a65c1ec
tree7f485ce6138653e3a6e172862f48a2212c8e9ca4
parentfea304ec875454360a3be106e0baad96032bf9fe
rust: pin-init: internal: init: handle code blocks early

`InitializerKind::Code` is a special case where it does not initialize a
field, and thus generate no guard and accessors. Handle it earlier and make
the rest of the code more linear.

Signed-off-by: Gary Guo <gary@garyguo.net>
rust/pin-init/internal/src/init.rs