(d *funcDecl, tag string, inType super.Type)
| 134 | } |
| 135 | |
| 136 | func (r *resolver) resolveFixed(d *funcDecl, tag string, inType super.Type) *funcDef { |
| 137 | save := r.t.scope |
| 138 | r.t.scope = NewScope(d.scope) |
| 139 | defer func() { |
| 140 | r.t.scope = save |
| 141 | }() |
| 142 | r.t.enterScope() |
| 143 | params := idsToStrings(d.lambda.Params) |
| 144 | for _, param := range params { |
| 145 | r.t.scope.BindSymbol(param, funcParamValue{}) |
| 146 | } |
| 147 | body, _ := r.t.expr(d.lambda.Expr, r.t.checker.unknown) //XXX need type |
| 148 | r.t.exitScope() |
| 149 | return &funcDef{ |
| 150 | tag: tag, |
| 151 | name: d.name, |
| 152 | params: params, |
| 153 | body: body, |
| 154 | } |
| 155 | } |
| 156 | |
| 157 | func (r *resolver) lookupFixed(id string, inType super.Type) (string, super.Type) { |
| 158 | if tag, ok := r.fixed[id]; ok { |
no test coverage detected