#[non_exhaustive]pub enum Effect {
Derive(String),
Inline(Inline),
}Expand description
Specifies the effect of a Rule.
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.
Derive(String)
Applies a derive macro to translated structs.
The given string is copied literally into the output and must be a path to a derive macro,
as accepted by the #[derive] attribute.
Inline(Inline)
Applies the #[inline] attribute to translated functions.
If multiple Inline effects apply, then for each function,
the last choice of inlining wins.
See The Rust Reference
for information on how the #[inline] attribute is interpreted.
Caution: Using this attribute is not always necessary to obtain inlining, and inlining is not always beneficial. Usage should be guided by profiling and benchmarks.
Trait Implementations§
impl Eq for Effect
impl StructuralPartialEq for Effect
Auto Trait Implementations§
impl Freeze for Effect
impl RefUnwindSafe for Effect
impl Send for Effect
impl Sync for Effect
impl Unpin for Effect
impl UnsafeUnpin for Effect
impl UnwindSafe for Effect
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> 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.