Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 1,062 for tparams (0.27 sec)

  1. src/go/doc/reader.go

    }
    
    // lookupTypeParam searches for type parameters named name within the tparams
    // field list, returning the relevant identifier if found, or nil if not.
    func lookupTypeParam(name string, tparams *ast.FieldList) *ast.Ident {
    	if tparams == nil {
    		return nil
    	}
    	for _, field := range tparams.List {
    		for _, id := range field.Names {
    			if id.Name == name {
    				return id
    			}
    		}
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 27.5K bytes
    - Viewed (0)
  2. src/go/types/interface.go

    				check.errorf(f.Type, InvalidSyntaxTree, "%s is not a method signature", typ)
    			}
    			continue // ignore
    		}
    
    		// The go/parser doesn't accept method type parameters but an ast.FuncType may have them.
    		if sig.tparams != nil {
    			var at positioner = f.Type
    			if ftyp, _ := f.Type.(*ast.FuncType); ftyp != nil && ftyp.TypeParams != nil {
    				at = ftyp.TypeParams
    			}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 09 17:24:42 UTC 2023
    - 8.1K bytes
    - Viewed (0)
  3. src/go/types/predicates.go

    		}
    
    		// In the case of generic signatures, we will substitute in yparams and
    		// yresults.
    		yparams := y.params
    		yresults := y.results
    
    		if x.TypeParams().Len() > 0 {
    			// We must ignore type parameter names when comparing x and y. The
    			// easiest way to do this is to substitute x's type parameters for y's.
    			xtparams := x.TypeParams().list()
    			ytparams := y.TypeParams().list()
    
    			var targs []Type
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 03:01:18 UTC 2024
    - 17.6K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/types2/predicates.go

    		}
    
    		// In the case of generic signatures, we will substitute in yparams and
    		// yresults.
    		yparams := y.params
    		yresults := y.results
    
    		if x.TypeParams().Len() > 0 {
    			// We must ignore type parameter names when comparing x and y. The
    			// easiest way to do this is to substitute x's type parameters for y's.
    			xtparams := x.TypeParams().list()
    			ytparams := y.TypeParams().list()
    
    			var targs []Type
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 03:01:18 UTC 2024
    - 17.5K bytes
    - Viewed (0)
  5. src/cmd/vendor/github.com/ianlancetaylor/demangle/ast.go

    	}
    
    	re = &RequiresExpr{Params: params, Requirements: requirements}
    	if r := fn(re); r != nil {
    		return r
    	}
    	return re
    }
    
    func (re *RequiresExpr) GoString() string {
    	return re.goString(0, "")
    }
    
    func (re *RequiresExpr) goString(indent int, field string) string {
    	var params strings.Builder
    	if len(re.Params) == 0 {
    		fmt.Fprintf(&params, "%*sParams: nil", indent+2, "")
    	} else {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 31 19:48:28 UTC 2024
    - 105.8K bytes
    - Viewed (0)
  6. src/go/types/typexpr.go

    	if orig == nil {
    		panic(fmt.Sprintf("%v: cannot instantiate %v", ix.Pos(), gtyp))
    	}
    
    	// create the instance
    	inst := asNamed(check.instance(ix.Pos(), orig, targs, nil, check.context()))
    
    	// orig.tparams may not be set up, so we need to do expansion later.
    	check.later(func() {
    		// This is an instance from the source, not from recursive substitution,
    		// and so it must be resolved during type-checking so that we can report
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 16.3K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/types2/typexpr.go

    	if orig == nil {
    		panic(fmt.Sprintf("%v: cannot instantiate %v", x.Pos(), gtyp))
    	}
    
    	// create the instance
    	inst := asNamed(check.instance(x.Pos(), orig, targs, nil, check.context()))
    
    	// orig.tparams may not be set up, so we need to do expansion later.
    	check.later(func() {
    		// This is an instance from the source, not from recursive substitution,
    		// and so it must be resolved during type-checking so that we can report
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 16.6K bytes
    - Viewed (0)
  8. src/go/types/object.go

    // NewTypeNameLazy returns a new defined type like NewTypeName, but it
    // lazily calls resolve to finish constructing the Named object.
    func _NewTypeNameLazy(pos token.Pos, pkg *Package, name string, load func(named *Named) (tparams []*TypeParam, underlying Type, methods []*Func)) *TypeName {
    	obj := NewTypeName(pos, pkg, name, nil)
    	NewNamed(obj, nil, nil).loader = load
    	return obj
    }
    
    // IsAlias reports whether obj is an alias name for a type.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 20:08:23 UTC 2024
    - 20.1K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/types2/object.go

    // NewTypeNameLazy returns a new defined type like NewTypeName, but it
    // lazily calls resolve to finish constructing the Named object.
    func NewTypeNameLazy(pos syntax.Pos, pkg *Package, name string, load func(named *Named) (tparams []*TypeParam, underlying Type, methods []*Func)) *TypeName {
    	obj := NewTypeName(pos, pkg, name, nil)
    	NewNamed(obj, nil, nil).loader = load
    	return obj
    }
    
    // IsAlias reports whether obj is an alias name for a type.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 20:08:23 UTC 2024
    - 20.1K bytes
    - Viewed (0)
  10. pkg/test/framework/components/echo/config/param/params.go

    // limitations under the License.
    
    package param
    
    // Params for a Template.
    type Params map[string]any
    
    // NewParams returns a new Params instance.
    func NewParams() Params {
    	return make(Params)
    }
    
    func (p Params) Get(k string) any {
    	return p[k]
    }
    
    func (p Params) GetWellKnown(k WellKnown) any {
    	return p[k.String()]
    }
    
    func (p Params) Set(k string, v any) Params {
    	p[k] = v
    	return p
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Jul 25 19:30:47 UTC 2022
    - 1.6K bytes
    - Viewed (0)
Back to top