@@ -293,17 +293,29 @@ impl LinkSelfContained {
293
293
}
294
294
295
295
/// Returns whether the self-contained linker component was enabled on the CLI, using the
296
- /// `-C link-self-contained=+linker` syntax, or one of the `true` shorcuts .
296
+ /// `-C link-self-contained=+linker` syntax, or one of the `true` shortcuts .
297
297
pub fn is_linker_enabled ( & self ) -> bool {
298
298
self . enabled_components . contains ( LinkSelfContainedComponents :: LINKER )
299
299
}
300
300
301
301
/// Returns whether the self-contained linker component was disabled on the CLI, using the
302
- /// `-C link-self-contained=-linker` syntax, or one of the `false` shorcuts .
302
+ /// `-C link-self-contained=-linker` syntax, or one of the `false` shortcuts .
303
303
pub fn is_linker_disabled ( & self ) -> bool {
304
304
self . disabled_components . contains ( LinkSelfContainedComponents :: LINKER )
305
305
}
306
306
307
+ // Returns whether the self-contained sanitizer component was enabled on the CLI, using the
308
+ // `-C link-self-contained=+sanitizers` syntax, or one of the `true` shortcuts.
309
+ pub fn is_sanitizers_enabled ( & self ) -> bool {
310
+ self . enabled_components . contains ( LinkSelfContainedComponents :: SANITIZERS )
311
+ }
312
+
313
+ /// Returns whether the self-contained linker component was disabled on the CLI, using the
314
+ /// `-C link-self-contained=-sanitizers` syntax, or one of the `false` shortcuts.
315
+ pub fn is_sanitizers_disabled ( & self ) -> bool {
316
+ self . disabled_components . contains ( LinkSelfContainedComponents :: SANITIZERS )
317
+ }
318
+
307
319
/// Returns CLI inconsistencies to emit errors: individual components were both enabled and
308
320
/// disabled.
309
321
fn check_consistency ( & self ) -> Option < LinkSelfContainedComponents > {
0 commit comments