Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 479 for recordDef (0.27 sec)

  1. src/cmd/compile/internal/types2/resolver.go

    	var fileScopes []*Scope
    	for fileNo, file := range check.files {
    		// The package identifier denotes the current package,
    		// but there is no corresponding package object.
    		check.recordDef(file.PkgName, nil)
    
    		fileScope := NewScope(pkg.scope, syntax.StartPos(file), syntax.EndPos(file), check.filename(fileNo))
    		fileScopes = append(fileScopes, fileScope)
    		check.recordScope(file, fileScope)
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 18 14:10:44 UTC 2024
    - 26.3K bytes
    - Viewed (0)
  2. src/go/types/resolver.go

    	var fileScopes []*Scope
    	for fileNo, file := range check.files {
    		// The package identifier denotes the current package,
    		// but there is no corresponding package object.
    		check.recordDef(file.Name, nil)
    
    		// Use the actual source file extent rather than *ast.File extent since the
    		// latter doesn't include comments which appear at the start or end of the file.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 17 16:22:59 UTC 2024
    - 26.1K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/types2/assignments.go

    	// Determine if the lhs is a (possibly parenthesized) identifier.
    	ident, _ := syntax.Unparen(lhs).(*syntax.Name)
    
    	// Don't evaluate lhs if it is the blank identifier.
    	if ident != nil && ident.Value == "_" {
    		check.recordDef(ident, nil)
    		return nil
    	}
    
    	// If the lhs is an identifier denoting a variable v, this reference
    	// is not a 'use' of v. Remember current value of v.used and restore
    	// after evaluating the lhs via check.expr.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Feb 23 21:21:43 UTC 2024
    - 16.4K bytes
    - Viewed (0)
  4. src/go/types/assignments.go

    	// Determine if the lhs is a (possibly parenthesized) identifier.
    	ident, _ := ast.Unparen(lhs).(*ast.Ident)
    
    	// Don't evaluate lhs if it is the blank identifier.
    	if ident != nil && ident.Name == "_" {
    		check.recordDef(ident, nil)
    		return nil
    	}
    
    	// If the lhs is an identifier denoting a variable v, this reference
    	// is not a 'use' of v. Remember current value of v.used and restore
    	// after evaluating the lhs via check.expr.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 03 18:48:38 UTC 2024
    - 16.4K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/types2/interface.go

    			if named := asNamed(def.typ); named != nil {
    				recvTyp = named
    			}
    		}
    		sig.recv = NewVar(f.Name.Pos(), check.pkg, "", recvTyp)
    
    		m := NewFunc(f.Name.Pos(), check.pkg, name, sig)
    		check.recordDef(f.Name, m)
    		ityp.methods = append(ityp.methods, m)
    	}
    
    	// All methods and embedded elements for this interface are collected;
    	// i.e., this interface may be used in a type set computation.
    	ityp.complete = true
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 09 17:24:42 UTC 2023
    - 6.2K bytes
    - Viewed (0)
  6. src/go/types/struct.go

    		fld := NewField(pos, check.pkg, name, typ, embedded)
    		// spec: "Within a struct, non-blank field names must be unique."
    		if name == "_" || check.declareInSet(&fset, pos, fld) {
    			fields = append(fields, fld)
    			check.recordDef(ident, fld)
    		}
    	}
    
    	// addInvalid adds an embedded field of invalid type to the struct for
    	// fields with errors; this keeps the number of struct fields in sync
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Feb 29 22:06:18 UTC 2024
    - 6.1K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/types2/struct.go

    		fld := NewField(pos, check.pkg, name, typ, embedded)
    		// spec: "Within a struct, non-blank field names must be unique."
    		if name == "_" || check.declareInSet(&fset, pos, fld) {
    			fields = append(fields, fld)
    			check.recordDef(ident, fld)
    		}
    	}
    
    	// addInvalid adds an embedded field of invalid type to the struct for
    	// fields with errors; this keeps the number of struct fields in sync
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Feb 29 22:06:18 UTC 2024
    - 6.6K bytes
    - Viewed (0)
  8. src/cmd/compile/internal/types2/labels.go

    					err.soft = true
    					err.addf(lbl.pos, "label %s already declared", name)
    					err.addAltDecl(alt)
    					err.report()
    					// ok to continue
    				} else {
    					b.insert(s)
    					check.recordDef(s.Label, lbl)
    				}
    				// resolve matching forward jumps and remove them from fwdJumps
    				i := 0
    				for _, jmp := range fwdJumps {
    					if jmp.Label.Value == name {
    						// match
    						lbl.used = true
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 7.2K bytes
    - Viewed (0)
  9. src/go/types/labels.go

    					err.soft = true
    					err.addf(lbl, "label %s already declared", name)
    					err.addAltDecl(alt)
    					err.report()
    					// ok to continue
    				} else {
    					b.insert(s)
    					check.recordDef(s.Label, lbl)
    				}
    				// resolve matching forward jumps and remove them from fwdJumps
    				i := 0
    				for _, jmp := range fwdJumps {
    					if jmp.Label.Name == name {
    						// match
    						lbl.used = true
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 7.2K bytes
    - Viewed (0)
  10. src/go/types/interface.go

    			if named := asNamed(def.typ); named != nil {
    				recvTyp = named
    			}
    		}
    		sig.recv = NewVar(name.Pos(), check.pkg, "", recvTyp)
    
    		m := NewFunc(name.Pos(), check.pkg, name.Name, sig)
    		check.recordDef(name, m)
    		ityp.methods = append(ityp.methods, m)
    	}
    
    	// All methods and embedded elements for this interface are collected;
    	// i.e., this interface may be used in a type set computation.
    	ityp.complete = true
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 09 17:24:42 UTC 2023
    - 8.1K bytes
    - Viewed (0)
Back to top