Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 90 for recvs (0.16 sec)

  1. src/cmd/vendor/golang.org/x/tools/internal/typesinternal/recv.go

    	"golang.org/x/tools/internal/aliases"
    )
    
    // ReceiverNamed returns the named type (if any) associated with the
    // type of recv, which may be of the form N or *N, or aliases thereof.
    // It also reports whether a Pointer was present.
    func ReceiverNamed(recv *types.Var) (isPtr bool, named *types.Named) {
    	t := recv.Type()
    	if ptr, ok := aliases.Unalias(t).(*types.Pointer); ok {
    		isPtr = true
    		t = ptr.Elem()
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 02:20:05 UTC 2024
    - 1.3K bytes
    - Viewed (0)
  2. test/typeparam/append.go

    package main
    
    type Recv <-chan int
    
    type sliceOf[E any] interface {
    	~[]E
    }
    
    func _Append[S sliceOf[T], T any](s S, t ...T) S {
    	return append(s, t...)
    }
    
    func main() {
    	recv := make(Recv)
    	a := _Append([]Recv{recv}, recv)
    	if len(a) != 2 || a[0] != recv || a[1] != recv {
    		panic(a)
    	}
    
    	recv2 := make(chan<- int)
    	a2 := _Append([]chan<- int{recv2}, recv2)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Mar 01 19:45:34 UTC 2022
    - 597 bytes
    - Viewed (0)
  3. src/cmd/compile/internal/typecheck/dcl.go

    func NewMethodType(sig *types.Type, recv *types.Type) *types.Type {
    	nrecvs := 0
    	if recv != nil {
    		nrecvs++
    	}
    
    	// TODO(mdempsky): Move this function to types.
    	// TODO(mdempsky): Preserve positions, names, and package from sig+recv.
    
    	params := make([]*types.Field, nrecvs+sig.NumParams())
    	if recv != nil {
    		params[0] = types.NewField(base.Pos, nil, recv)
    	}
    	for i, param := range sig.Params() {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Sep 14 13:15:50 UTC 2023
    - 3.1K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/walk/select.go

    		case ir.OSEND:
    			n := n.(*ir.SendStmt)
    			i = nsends
    			nsends++
    			c = n.Chan
    			elem = n.Value
    		case ir.OSELRECV2:
    			n := n.(*ir.AssignListStmt)
    			nrecvs++
    			i = ncas - nrecvs
    			recv := n.Rhs[0].(*ir.UnaryExpr)
    			c = recv.X
    			elem = n.Lhs[0]
    		}
    
    		casorder[i] = cas
    
    		setField := func(f string, val ir.Node) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Aug 22 01:53:41 UTC 2023
    - 7.8K bytes
    - Viewed (0)
  5. .git-blame-ignore-revs

    Guillaume Nodet <******@****.***> 1669127925 +0100
    Registered: Wed Jun 12 09:55:16 UTC 2024
    - Last Modified: Tue Nov 22 14:38:45 UTC 2022
    - 857 bytes
    - Viewed (0)
  6. pilot/test/xdstest/grpc.go

    	"istio.io/istio/pkg/log"
    	"istio.io/istio/pkg/sleep"
    )
    
    type slowClientStream struct {
    	grpc.ClientStream
    	recv, send time.Duration
    }
    
    func (w *slowClientStream) RecvMsg(m any) error {
    	if w.recv > 0 {
    		sleep.UntilContext(w.Context(), w.recv)
    		log.Infof("delayed recv for %v", w.recv)
    	}
    	return w.ClientStream.RecvMsg(m)
    }
    
    func (w *slowClientStream) SendMsg(m any) error {
    	if w.send > 0 {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue May 23 17:08:31 UTC 2023
    - 2.4K bytes
    - Viewed (0)
  7. src/cmd/vendor/golang.org/x/tools/internal/stdlib/stdlib.go

    //
    // Example: "(*Buffer).Grow" -> (true, "Buffer", "Grow")
    func (sym *Symbol) SplitMethod() (ptr bool, recv, name string) {
    	if sym.Kind != Method {
    		panic("not a method")
    	}
    	recv, name, _ = strings.Cut(sym.Name, ".")
    	recv = recv[len("(") : len(recv)-len(")")]
    	ptr = recv[0] == '*'
    	if ptr {
    		recv = recv[len("*"):]
    	}
    	return
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 02:20:05 UTC 2024
    - 2.4K bytes
    - Viewed (0)
  8. src/cmd/compile/internal/types2/selection.go

    func (s *Selection) Type() Type {
    	switch s.kind {
    	case MethodVal:
    		// The type of x.f is a method with its receiver type set
    		// to the type of x.
    		sig := *s.obj.(*Func).typ.(*Signature)
    		recv := *sig.recv
    		recv.typ = s.recv
    		sig.recv = &recv
    		return &sig
    
    	case MethodExpr:
    		// The type of x.f is a function (without receiver)
    		// and an additional first argument with the same type as x.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Feb 22 19:32:17 UTC 2024
    - 5.8K bytes
    - Viewed (0)
  9. src/go/types/selection.go

    func (s *Selection) Type() Type {
    	switch s.kind {
    	case MethodVal:
    		// The type of x.f is a method with its receiver type set
    		// to the type of x.
    		sig := *s.obj.(*Func).typ.(*Signature)
    		recv := *sig.recv
    		recv.typ = s.recv
    		sig.recv = &recv
    		return &sig
    
    	case MethodExpr:
    		// The type of x.f is a function (without receiver)
    		// and an additional first argument with the same type as x.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 03 18:48:38 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  10. pkg/config/analysis/analyzers/webhook/webhook.go

    					revs.InsertAll(ls.Values...)
    				}
    			}
    		}
    		if webhook.ObjectSelector != nil {
    			if r, f := webhook.ObjectSelector.MatchLabels[label.IoIstioRev.Name]; f {
    				revs.Insert(r)
    			}
    
    			for _, ls := range webhook.ObjectSelector.MatchExpressions {
    				if ls.Key == label.IoIstioRev.Name {
    					revs.InsertAll(ls.Values...)
    				}
    			}
    		}
    	}
    	return revs.UnsortedList()
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Sun May 05 03:44:57 UTC 2024
    - 6K bytes
    - Viewed (0)
Back to top