pub struct FunctionParameters { /* private fields */ }
Expand description
Function parameters used when creating this function, and that will become applied after
compilation to materialize the final CompiledCode
.
Implementations§
source§impl FunctionParameters
impl FunctionParameters
sourcepub fn base_srcloc(&self) -> SourceLoc
pub fn base_srcloc(&self) -> SourceLoc
Returns the base SourceLoc
.
If it was never explicitly set with ensure_base_srcloc
, will return an invalid
SourceLoc
.
sourcepub fn ensure_base_srcloc(&mut self, srcloc: SourceLoc) -> SourceLoc
pub fn ensure_base_srcloc(&mut self, srcloc: SourceLoc) -> SourceLoc
Sets the base SourceLoc
, if not set yet, and returns the base value.
sourcepub fn ensure_user_func_name(
&mut self,
name: UserExternalName,
) -> UserExternalNameRef
pub fn ensure_user_func_name( &mut self, name: UserExternalName, ) -> UserExternalNameRef
Retrieve a UserExternalNameRef
for the given name, or add a new one.
This method internally deduplicates same UserExternalName
so they map to the same
reference.
sourcepub fn reset_user_func_name(
&mut self,
index: UserExternalNameRef,
name: UserExternalName,
)
pub fn reset_user_func_name( &mut self, index: UserExternalNameRef, name: UserExternalName, )
Resets an already existing user function name to a new value.
sourcepub fn user_named_funcs(
&self,
) -> &PrimaryMap<UserExternalNameRef, UserExternalName>
pub fn user_named_funcs( &self, ) -> &PrimaryMap<UserExternalNameRef, UserExternalName>
Returns the internal mapping of UserExternalNameRef
to UserExternalName
.
Trait Implementations§
source§impl Clone for FunctionParameters
impl Clone for FunctionParameters
source§fn clone(&self) -> FunctionParameters
fn clone(&self) -> FunctionParameters
Returns a copy 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 PartialEq for FunctionParameters
impl PartialEq for FunctionParameters
impl StructuralPartialEq for FunctionParameters
Auto Trait Implementations§
impl Freeze for FunctionParameters
impl RefUnwindSafe for FunctionParameters
impl Send for FunctionParameters
impl Sync for FunctionParameters
impl Unpin for FunctionParameters
impl UnwindSafe for FunctionParameters
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)