1 // Verifies that when compiling with -Zsanitizer=option,
2 // the `#[cfg(sanitize = "option")]` attribute is configured.
4 // needs-sanitizer-support
8 // revisions: address leak memory thread
9 //[address]compile-flags: -Zsanitizer=address --cfg address
10 //[leak]compile-flags: -Zsanitizer=leak --cfg leak
11 //[memory]compile-flags: -Zsanitizer=memory --cfg memory
12 //[thread]compile-flags: -Zsanitizer=thread --cfg thread
14 #![feature(cfg_sanitize)]
16 #[cfg(all(sanitize = "address", address))]
19 #[cfg(all(sanitize = "leak", leak))]
22 #[cfg(all(sanitize = "memory", memory))]
25 #[cfg(all(sanitize = "thread", thread))]