pub enum CompilerKind {
Clang,
AppleClang,
Gcc,
Msvc,
Unknown,
}Expand description
Recognized C/C++ compiler family.
Variants§
Clang
LLVM Clang.
AppleClang
Apple-shipped Clang (Apple clang version …). Treated as
Clang-compatible for capability purposes; tracked separately
for diagnostics.
Gcc
GNU GCC / g++.
Msvc
Microsoft Visual C++ (cl.exe). Detected so Cabin can
produce a clear unsupported-backend error; the GCC/Clang
command pipeline cannot be used with this compiler.
Unknown
Compiler whose --version output Cabin does not recognize.
Capability detection treats this conservatively.
Implementations§
Source§impl CompilerKind
impl CompilerKind
Sourcepub fn is_clang_like(self) -> bool
pub fn is_clang_like(self) -> bool
Whether this compiler is part of the Clang family.
Sourcepub fn supports_gcc_style_command_line(self) -> bool
pub fn supports_gcc_style_command_line(self) -> bool
Whether this compiler accepts the GCC-style command line
the current C++ backend emits (-O<n>, -std=c++NN,
-MMD -MF, -DNAME, -Idir, …).
Trait Implementations§
Source§impl Clone for CompilerKind
impl Clone for CompilerKind
Source§fn clone(&self) -> CompilerKind
fn clone(&self) -> CompilerKind
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CompilerKind
impl Debug for CompilerKind
Source§impl<'de> Deserialize<'de> for CompilerKind
impl<'de> Deserialize<'de> for CompilerKind
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for CompilerKind
impl Display for CompilerKind
Source§impl Hash for CompilerKind
impl Hash for CompilerKind
Source§impl Ord for CompilerKind
impl Ord for CompilerKind
Source§fn cmp(&self, other: &CompilerKind) -> Ordering
fn cmp(&self, other: &CompilerKind) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for CompilerKind
impl PartialEq for CompilerKind
Source§fn eq(&self, other: &CompilerKind) -> bool
fn eq(&self, other: &CompilerKind) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialOrd for CompilerKind
impl PartialOrd for CompilerKind
Source§impl Serialize for CompilerKind
impl Serialize for CompilerKind
impl Copy for CompilerKind
impl Eq for CompilerKind
impl StructuralPartialEq for CompilerKind
Auto Trait Implementations§
impl Freeze for CompilerKind
impl RefUnwindSafe for CompilerKind
impl Send for CompilerKind
impl Sync for CompilerKind
impl Unpin for CompilerKind
impl UnsafeUnpin for CompilerKind
impl UnwindSafe for CompilerKind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.