MCPcopy Create free account
hub / github.com/RustCrypto/utils / zeroize_on_second_field

Function zeroize_on_second_field

zeroize_derive/src/lib.rs:640–649  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

638 #[test]
639 #[should_panic(expected = "#[zeroize(drop)] attribute is not allowed on struct fields")]
640 fn zeroize_on_second_field() {
641 parse_zeroize_test(stringify!(
642 struct Z {
643 a: String,
644 #[zeroize(drop)]
645 b: Vec<u8>,
646 c: [u8; 3],
647 }
648 ));
649 }
650
651 #[test]
652 #[should_panic(expected = "#[zeroize(drop)] attribute is not allowed on enum fields")]

Callers

nothing calls this directly

Calls 1

parse_zeroize_testFunction · 0.85

Tested by

no test coverage detected