fn define_fn<'c: 'b, 'b>(&'c mut self,
                             name: Id,
                             ty: Scheme,
                             params: Vec<VarDecl>,
                             free: Vec<VarDecl>,
                             body: TaggedTerm)
                             -> (Id, Vec<Id>) {
        let fun = FunDef::new(name, ty, params, free, body);
        let ent = self.global.entry(name).or_insert(P(fun));
        ((*ent).name(),
         (*ent)
             .fv()
             .iter()
             .map(|ref v| v.name())
             .collect())
    }
/// Add a function in top level definitions
Add a function in top level definitions
Add a function in top level definitions
fn define_fn<'c: 'b, 'b>(&'c mut self,
                             name: Id,
                             ty: Scheme,
                             params: Vec<VarDecl>,
                             free: Vec<VarDecl>,
                             body: TaggedTerm)
                             -> (Id, Vec<Id>) {
        let fun = FunDef::new(name, ty, params, free, body);
        let ent = self.global.entry(name).or_insert(P(fun));
        ((*ent).name(),
         (*ent)
             .fv()
             .iter()
             .map(|ref v| v.name())
             .collect())
    }
fn define_fn < ' c : ' b , ' b > ( & ' c mut self , name : Id , ty : Scheme , params : Vec < VarDecl > , free : Vec < VarDecl > , body : TaggedTerm ) -> ( Id , Vec < Id > ) { let fun = FunDef :: new ( name , ty , params , free , body ) ; let ent = self . global . entry ( name ) . or_insert ( P ( fun ) ) ; ( ( * ent ) . name ( ) , ( * ent ) . fv ( ) . iter ( ) . map ( | ref v | v . name ( ) ) . collect ( ) ) }
Add a function in top level definitions
Add a function in top level definitions
&'c mut self
name
Id
ty
Scheme
params
Vec<VarDecl>
free
Vec<VarDecl>
body
TaggedTerm
&'c mut self
name
Id
ty
Scheme
params
Vec<VarDecl>
free
Vec<VarDecl>
body
TaggedTerm