@@ -293,17 +293,29 @@ impl LinkSelfContained {
293293 }
294294
295295 /// 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 .
297297 pub fn is_linker_enabled ( & self ) -> bool {
298298 self . enabled_components . contains ( LinkSelfContainedComponents :: LINKER )
299299 }
300300
301301 /// 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 .
303303 pub fn is_linker_disabled ( & self ) -> bool {
304304 self . disabled_components . contains ( LinkSelfContainedComponents :: LINKER )
305305 }
306306
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+
307319 /// Returns CLI inconsistencies to emit errors: individual components were both enabled and
308320 /// disabled.
309321 fn check_consistency ( & self ) -> Option < LinkSelfContainedComponents > {
0 commit comments