pub enum AnnotationHandlerType {
OnDefine,
Before,
After,
Metadata,
ComptimePre,
ComptimePost,
}Expand description
Type of annotation lifecycle handler
Variants§
OnDefine
Called when function is defined (registration time)
Before
Called before each function invocation
After
Called after each function invocation
Metadata
Returns static metadata for tooling/optimization
ComptimePre
Compile-time pre-inference handler: comptime pre(target, ctx) { ... }
Can emit directives to concretize untyped function parameters.
ComptimePost
Compile-time post-inference handler: comptime post(target, ctx) { ... }
Can emit directives to synthesize return types and runtime bodies.
Trait Implementations§
Source§impl Clone for AnnotationHandlerType
impl Clone for AnnotationHandlerType
Source§fn clone(&self) -> AnnotationHandlerType
fn clone(&self) -> AnnotationHandlerType
Returns a duplicate of the value. Read more
1.0.0 · 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 AnnotationHandlerType
impl Debug for AnnotationHandlerType
Source§impl<'de> Deserialize<'de> for AnnotationHandlerType
impl<'de> Deserialize<'de> for AnnotationHandlerType
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 PartialEq for AnnotationHandlerType
impl PartialEq for AnnotationHandlerType
Source§impl Serialize for AnnotationHandlerType
impl Serialize for AnnotationHandlerType
impl StructuralPartialEq for AnnotationHandlerType
Auto Trait Implementations§
impl Freeze for AnnotationHandlerType
impl RefUnwindSafe for AnnotationHandlerType
impl Send for AnnotationHandlerType
impl Sync for AnnotationHandlerType
impl Unpin for AnnotationHandlerType
impl UnsafeUnpin for AnnotationHandlerType
impl UnwindSafe for AnnotationHandlerType
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