pub(crate) fn take_var(
        &mut self,
        name: &str,
        source_id: SourceId,
        span: Span,
    ) -> CompileResult<&Var> {
        match self.try_take_var(name, source_id, span)? {
            Some(var) => Ok(var),
            None => Err(CompileError::new(
                span,
                CompileErrorKind::MissingLocal {
                    name: name.to_owned(),
                },
            )),
        }
    }
/// Take the local with the given name.
Take the local with the given name.
Take the local with the given name .
pub(crate) fn take_var(
        &mut self,
        name: &str,
        source_id: SourceId,
        span: Span,
    ) -> CompileResult<&Var> {
        match self.try_take_var(name, source_id, span)? {
            Some(var) => Ok(var),
            None => Err(CompileError::new(
                span,
                CompileErrorKind::MissingLocal {
                    name: name.to_owned(),
                },
            )),
        }
    }
pub ( crate ) fn take_var ( & mut self , name : & str , source_id : SourceId , span : Span , ) -> CompileResult < & Var > { match self . try_take_var ( name , source_id , span ) ? { Some ( var ) => Ok ( var ) , None => Err ( CompileError :: new ( span , CompileErrorKind :: MissingLocal { name : name . to_owned ( ) , } , ) ) , } }
Take the local with the given name.
Take the local with the given name .
&mut self
name
&str
source_id
SourceId
span
Span
&mut self
name
&str
source_id
SourceId
span
Span