linux/rust/pin-init/examples
Benno Lossin fc3870dc5c rust: pin-init: examples, tests: use ignore instead of conditionally compiling tests
Change `#[cfg(cond)]` to `#[cfg_attr(not(cond), ignore)]` on tests.

Ignoring tests instead of disabling them still makes them appear in the
test list, but with `ignored`. It also still compiles the code in those
cases.

Some tests still need to be ignore, because they use types that are not
present when the condition is false. For example the condition is
`feature = std` and then it uses `std:🧵:Thread`.

Suggested-by: Alice Ryhl <aliceryhl@google.com>
Link: https://lore.kernel.org/all/aDC9y829vZZBzZ2p@google.com
Link: b004dd8e64
Reviewed-by: Christian Schrefl <chrisi.schrefl@gmail.com>
Link: https://lore.kernel.org/all/20250605155258.573391-1-lossin@kernel.org
Signed-off-by: Benno Lossin <lossin@kernel.org>
2025-06-11 21:13:57 +02:00
..
big_struct_in_place.rs rust: pin-init: rename zeroed to init_zeroed 2025-06-11 21:13:56 +02:00
error.rs
linked_list.rs rust: pin-init: examples, tests: add conditional compilation in order to compile under any feature combination 2025-06-11 21:13:56 +02:00
mutex.rs rust: pin-init: examples, tests: add conditional compilation in order to compile under any feature combination 2025-06-11 21:13:56 +02:00
pthread_mutex.rs rust: pin-init: examples, tests: use ignore instead of conditionally compiling tests 2025-06-11 21:13:57 +02:00
static_init.rs rust: pin-init: examples, tests: add conditional compilation in order to compile under any feature combination 2025-06-11 21:13:56 +02:00