Change-Id: I5daeb8f00044c86bb10510afbc6886898e61ba15
Reviewed-on: https://go-review.googlesource.com/38570
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
// function literals aka closures
func closurehdr(ntype *Node) {
n := nod(OCLOSURE, nil, nil)
+ n.Func.SetIsHiddenClosure(Curfn != nil)
n.Func.Ntype = ntype
n.Func.Depth = funcdepth
n.Func.Outerfunc = Curfn
// create the function
xfunc := nod(ODCLFUNC, nil, nil)
+ xfunc.Func.SetIsHiddenClosure(Curfn != nil)
xfunc.Func.Nname = newfuncname(closurename(func_))
xfunc.Func.Nname.Sym.SetExported(true) // disable export
}
n = &x.Node
n.Func = &x.Func
- n.Func.SetIsHiddenClosure(Curfn != nil)
case ONAME:
var x struct {
Node