#[non_exhaustive]pub enum Profile<'a> {
Dev,
Release,
Test,
Bench,
Other(Cow<'a, str>),
}
Expand description
Profile of the current build.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Dev
The dev profile is used for normal development and debugging.
It is the default for build commands like cargo build
.
dev
Release
The release profile is intended for optimized artifacts used for releases and in production.
This profile is used when the --release
flag is used, and is the default for cargo install
.
release
Test
The test profile is used for building tests, or when benchmarks are built in debug mode with cargo build
.
test
Bench
The bench profile is used for building benchmarks, or when tests are built with the --release
flag.
bench
Other(Cow<'a, str>)
Unknown value
Implementations§
Trait Implementations§
Source§impl<'a> Ord for Profile<'a>
impl<'a> Ord for Profile<'a>
1.21.0 · 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<'a> PartialOrd for Profile<'a>
impl<'a> PartialOrd for Profile<'a>
impl<'a> Eq for Profile<'a>
impl<'a> StructuralPartialEq for Profile<'a>
Auto Trait Implementations§
impl<'a> Freeze for Profile<'a>
impl<'a> RefUnwindSafe for Profile<'a>
impl<'a> Send for Profile<'a>
impl<'a> Sync for Profile<'a>
impl<'a> Unpin for Profile<'a>
impl<'a> UnwindSafe for Profile<'a>
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