- Sort Score
- Result 10 results
- Languages All
Results 1 - 7 of 7 for LookupNum (0.57 sec)
-
src/cmd/compile/internal/types/pkg.go
pkg = nopkg } if s := pkg.Syms[string(name)]; s != nil { return s } str := InternString(name) return pkg.Lookup(str) } // LookupNum looks up the symbol starting with prefix and ending with // the decimal n. If prefix is too long, LookupNum panics. func (pkg *Pkg) LookupNum(prefix string, n int) *Sym { var buf [20]byte // plenty long enough for all current users copy(buf[:], prefix)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Nov 08 16:28:50 UTC 2023 - 3.1K bytes - Viewed (0) -
src/cmd/compile/internal/typecheck/syms.go
base.Fatalf("autolabel prefix must start with '.', have %q", prefix) } fn := ir.CurFunc if ir.CurFunc == nil { base.Fatalf("autolabel outside function") } n := fn.Label fn.Label++ return LookupNum(prefix, int(n)) } func Lookup(name string) *types.Sym { return types.LocalPkg.Lookup(name) } // InitRuntime loads the definitions for the low-level runtime functions,
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Aug 22 21:17:13 UTC 2023 - 3.7K bytes - Viewed (0) -
src/cmd/compile/internal/typecheck/subr.go
) func AssignConv(n ir.Node, t *types.Type, context string) ir.Node { return assignconvfn(n, t, func() string { return context }) } // LookupNum returns types.LocalPkg.LookupNum(prefix, n). func LookupNum(prefix string, n int) *types.Sym { return types.LocalPkg.LookupNum(prefix, n) } // Given funarg struct list, return list of fn args. func NewFuncParams(origs []*types.Field) []*types.Field {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Oct 05 19:45:58 UTC 2023 - 20.2K bytes - Viewed (0) -
src/cmd/compile/internal/noder/noder.go
// To make it unique within a package and also uncallable, // the name, normally "pkg.init", is altered to "pkg.init.0". var renameinitgen int func Renameinit() *types.Sym { s := typecheck.LookupNum("init.", renameinitgen) renameinitgen++ return s } func checkEmbed(decl *syntax.VarDecl, haveEmbed, withinFunc bool) error { switch { case !haveEmbed:
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Oct 11 20:40:57 UTC 2023 - 12.5K bytes - Viewed (0) -
src/cmd/compile/internal/staticinit/sched.go
// StaticName returns a name backed by a (writable) static data symbol. // Use readonlystaticname for read-only node. func StaticName(t *types.Type) *ir.Name { // Don't use LookupNum; it interns the resulting string, but these are all unique. sym := typecheck.Lookup(fmt.Sprintf("%s%d", obj.StaticNamePref, statuniqgen)) statuniqgen++ n := ir.NewNameAt(base.Pos, sym, t) sym.Def = n
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 17:16:14 UTC 2024 - 30.7K bytes - Viewed (0) -
src/cmd/compile/internal/ir/func.go
} declareParams := func(params []*types.Field, ctxt Class, prefix string, offset int) { for i, param := range params { sym := param.Sym if sym == nil || sym.IsBlank() { sym = fn.Sym().Pkg.LookupNum(prefix, i) } name := NewNameAt(param.Pos, sym, param.Type) name.Class = ctxt name.Curfn = fn fn.Dcl[offset+i] = name if setNname { param.Nname = name } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:05:44 UTC 2024 - 21.1K bytes - Viewed (0) -
src/cmd/compile/internal/typecheck/func.go
it := NewClosureStructIter(clo.Func.ClosureVars) i := 0 for { n, typ, _ := it.Next() if n == nil { break } fields[1+i] = types.NewField(base.AutogeneratedPos, types.LocalPkg.LookupNum("X", i), typ) i++ } typ := types.NewStruct(fields) typ.SetNoalg(true) return typ } // MethodValueType returns the struct type used to hold all the information
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Mar 06 15:23:18 UTC 2024 - 21.1K bytes - Viewed (0)