• Michael Hudson-Doyle's avatar
    cmd/link: use ctxt.{Lookup,ROLookup} in favour of function versions of same · 324f6ab4
    Michael Hudson-Doyle authored
    Done with two eg templates:
    
    package p
    
    import (
    	"cmd/link/internal/ld"
    )
    
    func before(ctxt *ld.Link, name string, v int) *ld.Symbol {
    	return ld.Linklookup(ctxt, name, v)
    }
    func after(ctxt *ld.Link, name string, v int) *ld.Symbol {
    	return ctxt.Syms.Lookup(name, v)
    }
    
    package p
    
    import (
    	"cmd/link/internal/ld"
    )
    
    func before(ctxt *ld.Link, name string, v int) *ld.Symbol {
    	return ld.Linkrlookup(ctxt, name, v)
    }
    func after(ctxt *ld.Link, name string, v int) *ld.Symbol {
    	return ctxt.Syms.ROLookup(name, v)
    }
    
    Change-Id: I00647dbf62294557bd24c29ad1f108fc786335f1
    Reviewed-on: https://go-review.googlesource.com/29343
    Run-TryBot: Michael Hudson-Doyle <michael.hudson@canonical.com>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    Reviewed-by: default avatarIan Lance Taylor <iant@golang.org>
    324f6ab4
pe.go 31.2 KB