Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 24 for chanType (0.14 sec)

  1. src/runtime/type.go

    	return unsafe.Pointer(res)
    }
    
    type uncommontype = abi.UncommonType
    
    type interfacetype = abi.InterfaceType
    
    type maptype = abi.MapType
    
    type arraytype = abi.ArrayType
    
    type chantype = abi.ChanType
    
    type slicetype = abi.SliceType
    
    type functype = abi.FuncType
    
    type ptrtype = abi.PtrType
    
    type name = abi.Name
    
    type structtype = abi.StructType
    
    func pkgPath(n name) string {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:17:26 UTC 2024
    - 12.7K bytes
    - Viewed (0)
  2. src/internal/abi/type.go

    	InvalidDir ChanDir = 0
    )
    
    // ChanType represents a channel type
    type ChanType struct {
    	Type
    	Elem *Type
    	Dir  ChanDir
    }
    
    type structTypeUncommon struct {
    	StructType
    	u UncommonType
    }
    
    // ChanDir returns the direction of t if t is a channel type, otherwise InvalidDir (0).
    func (t *Type) ChanDir() ChanDir {
    	if t.Kind() == Chan {
    		ch := (*ChanType)(unsafe.Pointer(t))
    		return ch.Dir
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 17 21:09:59 UTC 2024
    - 21.8K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/typecheck/_builtin/runtime.go

    func mapiternext(hiter *any)
    func mapclear(mapType *byte, hmap map[any]any)
    
    // *byte is really *runtime.Type
    func makechan64(chanType *byte, size int64) (hchan chan any)
    func makechan(chanType *byte, size int) (hchan chan any)
    func chanrecv1(hchan <-chan any, elem *any)
    func chanrecv2(hchan <-chan any, elem *any) bool
    func chansend1(hchan chan<- any, elem *any)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 21 21:08:03 UTC 2024
    - 10.6K bytes
    - Viewed (0)
  4. src/internal/reflectlite/type.go

    // to describe a non-defined type with no methods.
    type uncommonType = abi.UncommonType
    
    // arrayType represents a fixed array type.
    type arrayType = abi.ArrayType
    
    // chanType represents a channel type.
    type chanType = abi.ChanType
    
    type funcType = abi.FuncType
    
    type interfaceType = abi.InterfaceType
    
    // ptrType represents a pointer type.
    type ptrType = abi.PtrType
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 17:01:54 UTC 2024
    - 16.2K bytes
    - Viewed (0)
  5. src/go/ast/ast.go

    	}
    
    	// A MapType node represents a map type.
    	MapType struct {
    		Map   token.Pos // position of "map" keyword
    		Key   Expr
    		Value Expr
    	}
    
    	// A ChanType node represents a channel type.
    	ChanType struct {
    		Begin token.Pos // position of "chan" keyword or "<-" (whichever comes first)
    		Arrow token.Pos // position of "<-" (token.NoPos if there is no "<-")
    		Dir   ChanDir   // channel direction
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 28 21:32:41 UTC 2024
    - 35.6K bytes
    - Viewed (0)
  6. src/cmd/vendor/golang.org/x/tools/go/ast/astutil/enclosing.go

    			children = append(children,
    				tok(n.Case, len("default")))
    		} else {
    			children = append(children,
    				tok(n.Case, len("case")))
    		}
    		children = append(children, tok(n.Colon, len(":")))
    
    	case *ast.ChanType:
    		switch n.Dir {
    		case ast.RECV:
    			children = append(children, tok(n.Begin, len("<-chan")))
    		case ast.SEND:
    			children = append(children, tok(n.Begin, len("chan<-")))
    		case ast.RECV | ast.SEND:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Dec 18 21:28:13 UTC 2023
    - 15.9K bytes
    - Viewed (0)
  7. src/go/internal/gcimporter/iimport.go

    type ident struct {
    	pkg  *types.Package
    	name string
    }
    
    const predeclReserved = 32
    
    type itag uint64
    
    const (
    	// Types
    	definedType itag = iota
    	pointerType
    	sliceType
    	arrayType
    	chanType
    	mapType
    	signatureType
    	structType
    	interfaceType
    	typeParamType
    	instanceType
    	unionType
    )
    
    // iImportData imports a package from the serialized package data
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 19.2K bytes
    - Viewed (0)
  8. src/runtime/chan.go

    }
    
    //go:linkname reflect_makechan reflect.makechan
    func reflect_makechan(t *chantype, size int) *hchan {
    	return makechan(t, size)
    }
    
    func makechan64(t *chantype, size int64) *hchan {
    	if int64(int(size)) != size {
    		panic(plainError("makechan: size out of range"))
    	}
    
    	return makechan(t, int(size))
    }
    
    func makechan(t *chantype, size int) *hchan {
    	elem := t.Elem
    
    	// compiler checks this but be safe.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:16:50 UTC 2024
    - 25.9K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/syntax/printer.go

    		}
    		p.print(_Rbrace)
    
    	case *MapType:
    		p.print(_Map, _Lbrack, n.Key, _Rbrack, n.Value)
    
    	case *ChanType:
    		if n.Dir == RecvOnly {
    			p.print(_Arrow)
    		}
    		p.print(_Chan)
    		if n.Dir == SendOnly {
    			p.print(_Arrow)
    		}
    		p.print(blank)
    		if e, _ := n.Elem.(*ChanType); n.Dir == 0 && e != nil && e.Dir == RecvOnly {
    			// don't print chan (<-chan T) as chan <-chan T
    			p.print(_Lparen)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Aug 24 07:17:27 UTC 2023
    - 21.5K bytes
    - Viewed (0)
  10. src/cmd/vendor/golang.org/x/tools/internal/analysisinternal/analysis.go

    		dir := ast.ChanDir(t.Dir())
    		if t.Dir() == types.SendRecv {
    			dir = ast.SEND | ast.RECV
    		}
    		value := TypeExpr(f, pkg, t.Elem())
    		if value == nil {
    			return nil
    		}
    		return &ast.ChanType{
    			Dir:   dir,
    			Value: value,
    		}
    	case *types.Signature:
    		var params []*ast.Field
    		for i := 0; i < t.Params().Len(); i++ {
    			p := TypeExpr(f, pkg, t.Params().At(i).Type())
    			if p == nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 04 16:19:04 UTC 2024
    - 11.7K bytes
    - Viewed (0)
Back to top