Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 81 for pkgName (0.15 sec)

  1. src/cmd/compile/internal/syntax/walk.go

    }
    
    func (w walker) node(n Node) {
    	if n == nil {
    		panic("nil node")
    	}
    
    	w.v = w.v.Visit(n)
    	if w.v == nil {
    		return
    	}
    
    	switch n := n.(type) {
    	// packages
    	case *File:
    		w.node(n.PkgName)
    		w.declList(n.DeclList)
    
    	// declarations
    	case *ImportDecl:
    		if n.LocalPkgName != nil {
    			w.node(n.LocalPkgName)
    		}
    		w.node(n.Path)
    
    	case *ConstDecl:
    		w.nameList(n.NameList)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 17 19:55:04 UTC 2023
    - 5.7K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/types/fmt.go

    	fmtTypeID
    	fmtTypeIDName
    )
    
    // Sym
    
    // Format implements formatting for a Sym.
    // The valid formats are:
    //
    //	%v	Go syntax: Name for symbols in the local package, PkgName.Name for imported symbols.
    //	%+v	Debug syntax: always include PkgName. prefix even for local names.
    //	%S	Short syntax: Name only, no matter what.
    func (s *Sym) Format(f fmt.State, verb rune) {
    	mode := fmtGo
    	switch verb {
    	case 'v', 'S':
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Sep 12 15:41:17 UTC 2023
    - 15.7K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/pkginit/initAsanGlobals.go

    		c = ir.NewSelectorExpr(base.Pos, ir.ODOT, c, lname("data"))
    		setField("name", c, i)
    
    		// Set the name of package being compiled as a unique identifier of a module.
    		// asanModulename = pkgName + "\000"
    		init.Append(typecheck.Stmt(ir.NewAssignStmt(base.Pos, asanModulename, ir.NewString(base.Pos, types.LocalPkg.Name+"\000"))))
    		c = tconv(typecheck.NodAddr(asanModulename), types.Types[types.TUNSAFEPTR])
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Aug 17 19:36:24 UTC 2023
    - 8.7K bytes
    - Viewed (0)
  4. src/cmd/cover/cfg_test.go

    	incfg := filepath.Join(outdir, tag+"incfg.txt")
    	outcfg := filepath.Join(outdir, "outcfg.txt")
    	p := covcmd.CoverPkgConfig{
    		PkgPath:      ppath,
    		PkgName:      pname,
    		Granularity:  gran,
    		OutConfig:    outcfg,
    		EmitMetaFile: mpath,
    	}
    	data, err := json.Marshal(p)
    	if err != nil {
    		t.Fatalf("json.Marshal failed: %v", err)
    	}
    	writeFile(t, incfg, data)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 15 12:51:11 UTC 2024
    - 7.8K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/types2/api_test.go

    		}
    	}
    	return conf.Check(f.PkgName.Value, []*syntax.File{f}, info)
    }
    
    func mustTypecheck(src string, conf *Config, info *Info) *Package {
    	pkg, err := typecheck(src, conf, info)
    	if err != nil {
    		panic(err) // so we don't need to pass *testing.T
    	}
    	return pkg
    }
    
    // pkgName extracts the package name from src, which must contain a package header.
    func pkgName(src string) string {
    	const kw = "package "
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 20:08:23 UTC 2024
    - 93.3K bytes
    - Viewed (0)
  6. src/go/types/eval_test.go

    func TestIssue65898(t *testing.T) {
    	const src = `
    package p
    func _[A any](A) {}
    `
    
    	fset := token.NewFileSet()
    	f := mustParse(fset, src)
    
    	var conf types.Config
    	pkg, err := conf.Check(pkgName(src), fset, []*ast.File{f}, nil)
    	if err != nil {
    		t.Fatal(err)
    	}
    
    	for _, d := range f.Decls {
    		if fun, _ := d.(*ast.FuncDecl); fun != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 15 19:56:15 UTC 2024
    - 8.3K bytes
    - Viewed (0)
  7. src/cmd/cover/cover.go

    	f.fn.counterVar = ""
    }
    
    func annotate(names []string) {
    	var p *Package
    	if *pkgcfg != "" {
    		pp := pkgconfig.PkgPath
    		pn := pkgconfig.PkgName
    		mp := pkgconfig.ModulePath
    		mdb, err := encodemeta.NewCoverageMetaDataBuilder(pp, pn, mp)
    		if err != nil {
    			log.Fatalf("creating coverage meta-data builder: %v\n", err)
    		}
    		p = &Package{
    			mdb: mdb,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 19:41:17 UTC 2024
    - 34.5K bytes
    - Viewed (0)
  8. src/go/internal/gcimporter/gcimporter_test.go

    			// that was type-checked directly.
    			compile(t, rootDir, entry.Name(), filepath.Join(tmpdir, "testdata"), nil, filename)
    			pkgName := strings.TrimSuffix(entry.Name(), ".go")
    			imported := importPkg(t, "./testdata/"+pkgName, tmpdir)
    			checked := checkFile(t, filename, src)
    
    			seen := make(map[string]bool)
    			for _, name := range imported.Scope().Names() {
    				if !token.IsExported(name) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 16:22:59 UTC 2024
    - 21.9K bytes
    - Viewed (0)
  9. src/go/types/check.go

    	versions      map[*ast.File]string      // maps files to version strings (each file has an entry); shared with Info.FileVersions if present
    	imports       []*PkgName                // list of imported packages
    	dotImportMap  map[dotImportKey]*PkgName // maps dot-imported objects to the package they were dot-imported through
    	recvTParamMap map[*ast.Ident]*TypeParam // maps blank receiver type parameters to their type
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 23.1K bytes
    - Viewed (0)
  10. src/internal/coverage/defs.go

    // meta-data blob, e.g. the coverage meta-data payload
    // computed for a given Go package.
    type MetaSymbolHeader struct {
    	Length     uint32 // size of meta-symbol payload in bytes
    	PkgName    uint32 // string table index
    	PkgPath    uint32 // string table index
    	ModulePath uint32 // string table index
    	MetaHash   [16]byte
    	_          byte    // currently unused
    	_          [3]byte // padding
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Aug 14 12:51:16 UTC 2023
    - 11.9K bytes
    - Viewed (0)
Back to top