pub struct FnOf<A, R>(/* private fields */);Expand description
Names a callable with a complete canonical parameter and result signature.
The shared carrier always clones, regardless of argument/result capabilities. Equality and default construction are not implied.
§Examples
use cel_runtime::{FnOf, Nil, Leaf, ValueRepr, Callable, CNil};
let _: <FnOf<Nil, Leaf<i32>> as ValueRepr>::Value =
Callable::from_fn(|_: &CNil<()>| Ok(7));Non-list arguments cannot authorize a callable representation:
ⓘ
use cel_runtime::{FnOf, Leaf, ValueRepr};
let _ = FnOf::<Leaf<()>, Leaf<i32>>::value_type();Trait Implementations§
Auto Trait Implementations§
impl<A, R> Freeze for FnOf<A, R>
impl<A, R> RefUnwindSafe for FnOf<A, R>
impl<A, R> Send for FnOf<A, R>
impl<A, R> Sync for FnOf<A, R>
impl<A, R> Unpin for FnOf<A, R>
impl<A, R> UnsafeUnpin for FnOf<A, R>
impl<A, R> UnwindSafe for FnOf<A, R>
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