Struct datafusion_jit::api::FunctionBuilder
source · [−]pub struct FunctionBuilder { /* private fields */ }
Expand description
Function builder API. Stores the state while we are constructing an AST for a function.
Implementations
sourceimpl FunctionBuilder
impl FunctionBuilder
sourcepub fn param(self, name: impl Into<String>, ty: JITType) -> Self
pub fn param(self, name: impl Into<String>, ty: JITType) -> Self
Add one more parameter to the function.
sourcepub fn ret(self, name: impl Into<String>, ty: JITType) -> Self
pub fn ret(self, name: impl Into<String>, ty: JITType) -> Self
Set return type for the function. Functions are of void
type by default if
you do not set the return type.
sourcepub fn enter_block(&mut self) -> CodeBlock<'_>
pub fn enter_block(&mut self) -> CodeBlock<'_>
Enter the function body at start the building.
Auto Trait Implementations
impl !RefUnwindSafe for FunctionBuilder
impl !Send for FunctionBuilder
impl !Sync for FunctionBuilder
impl Unpin for FunctionBuilder
impl !UnwindSafe for FunctionBuilder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more