- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 53 for interfaces (0.17 sec)
-
src/bytes/reader.go
func (r *Reader) Size() int64 { return int64(len(r.s)) } // Read implements the [io.Reader] interface. func (r *Reader) Read(b []byte) (n int, err error) { if r.i >= int64(len(r.s)) { return 0, io.EOF } r.prevRune = -1 n = copy(b, r.s[r.i:]) r.i += int64(n) return } // ReadAt implements the [io.ReaderAt] interface. func (r *Reader) ReadAt(b []byte, off int64) (n int, err error) {
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Fri Oct 13 17:10:31 GMT 2023 - 3.9K bytes - Viewed (0) -
doc/go1.17_spec.html
func(prefix string, values ...int) func(a, b int, z float64, opt ...interface{}) (success bool) func(int, int, float64) (float64, *[]int) func(n int) func(p *T) </pre> <h3 id="Interface_types">Interface types</h3> <p> An interface type specifies a <a href="#Method_sets">method set</a> called its <i>interface</i>. A variable of interface type can store a value of any type with a method set
HTML - Registered: Tue May 07 11:14:38 GMT 2024 - Last Modified: Thu Apr 11 20:22:45 GMT 2024 - 211.6K bytes - Viewed (0) -
doc/go_spec.html
struct{f any} comparable // satisfied: struct{f any} is comparable and implements the basic interface any any interface{ comparable; m() } // not satisfied: any does not implement the basic interface interface{ m() }
HTML - Registered: Tue May 07 11:14:38 GMT 2024 - Last Modified: Thu May 02 22:43:51 GMT 2024 - 279.6K bytes - Viewed (0) -
src/cmd/api/testdata/src/pkg/p1/p1.go
var ( Y int X I ) type Namer interface { Name() string } type I interface { Namer ptwo.Twoer Set(name string, balance int64) // Deprecated: use GetNamed. Get(string) int64 GetNamed(string) (balance int64) private() } type Public interface { X() Y() } // Deprecated: Use Unexported. type Private interface { X() y() } type Error interface {
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Fri Dec 02 16:29:41 GMT 2022 - 3.3K bytes - Viewed (0) -
src/cmd/cgo/ast_go118.go
// license that can be found in the LICENSE file. //go:build !compiler_bootstrap package main import ( "go/ast" "go/token" ) func (f *File) walkUnexpected(x interface{}, context astContext, visit func(*File, interface{}, astContext)) { switch n := x.(type) { default: error_(token.NoPos, "unexpected type %T in walk", x) panic("unexpected type") case *ast.IndexListExpr:
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Wed Nov 30 21:45:10 GMT 2022 - 730 bytes - Viewed (0) -
src/cmd/cgo/ast.go
} func (f *File) validateIdents(x interface{}, context astContext) { if x, ok := x.(*ast.Ident); ok { if f.isMangledName(x.Name) { error_(x.Pos(), "identifier %q may conflict with identifiers generated by cgo", x.Name) } } } // Save various references we are going to need later. func (f *File) saveExprs(x interface{}, context astContext) { switch x := x.(type) { case *ast.Expr:
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Wed Jun 07 16:54:27 GMT 2023 - 14.3K bytes - Viewed (0) -
src/cmd/cgo/doc.go
argument, so that the host linker will be able to find 'sin' in the math library. cmd/link Command Line Interface The go command and any other Go-aware build systems invoke cmd/link to link a collection of packages into a single binary. By default, cmd/link will present the same interface it does today: cmd/link main.a produces a file named a.out, even if cmd/link does so by invoking the host
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Sun Mar 31 09:02:45 GMT 2024 - 42.1K bytes - Viewed (0) -
src/archive/zip/reader_test.go
0x78, 0x74, 0x50, 0x4b, 0x05, 0x06, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x39, 0x00, 0x00, 0x00, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, } // Read in the archive with the OpenReader interface name := filepath.Join(t.TempDir(), "test.zip") err := os.WriteFile(name, data, 0644) if err != nil { t.Fatalf("Unable to write out the bugos zip entry") } r, err := OpenReader(name)
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Wed Mar 27 18:23:49 GMT 2024 - 55.3K bytes - Viewed (0) -
src/cmd/cgo/internal/test/callback.go
//export goFoo func goFoo() { x := 1 for i := 0; i < 10000; i++ { // variadic call mallocs + writes to variadic(x, x, x) if x != 1 { panic("bad x") } } } func variadic(x ...interface{}) {} func testBlocking(t *testing.T) { c := make(chan int) go func() { for i := 0; i < 10; i++ { c <- <-c } }() nestedCall(func() { for i := 0; i < 10; i++ { c <- i
Go - Registered: Tue Apr 23 11:13:09 GMT 2024 - Last Modified: Fri May 12 12:00:02 GMT 2023 - 111.5K bytes - Viewed (0) -
src/cmd/api/testdata/src/pkg/p1/golden.txt
pkg p1, type I interface, Set(string, int64) pkg p1, type I interface, unexported methods pkg p1, type MyInt int pkg p1, type Namer interface { Name } pkg p1, type Namer interface, Name() string pkg p1, type Private interface, X() pkg p1, type Private interface, unexported methods pkg p1, type Private //deprecated pkg p1, type Public interface { X, Y } pkg p1, type Public interface, X() pkg p1, type Public interface, Y() pkg p1, type S struct
Plain Text - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Fri Dec 02 16:29:41 GMT 2022 - 3.6K bytes - Viewed (0)