- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 22 for read (0.26 sec)
-
src/archive/zip/fuzz_test.go
func FuzzReader(f *testing.F) { testdata, err := os.ReadDir("testdata") if err != nil { f.Fatalf("failed to read testdata directory: %s", err) } for _, de := range testdata { if de.IsDir() { continue } b, err := os.ReadFile(filepath.Join("testdata", de.Name())) if err != nil { f.Fatalf("failed to read testdata: %s", err) } f.Add(b) } f.Fuzz(func(t *testing.T, b []byte) {
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Thu Jan 13 18:06:33 GMT 2022 - 1.7K bytes - Viewed (0) -
src/bytes/reader_test.go
t.Errorf("r.Len(): got %d, want %d", got, want) } if n, err := r.Read(make([]byte, 10)); err != nil || n != 10 { t.Errorf("Read failed: read %d %v", n, err) } if got, want := r.Len(), 1; got != want { t.Errorf("r.Len(): got %d, want %d", got, want) } if n, err := r.Read(make([]byte, 1)); err != nil || n != 1 { t.Errorf("Read failed: read %d %v; want 1, nil", n, err) } if got, want := r.Len(), 0; got != want {
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Mon Dec 13 18:45:54 GMT 2021 - 8K bytes - Viewed (0) -
src/archive/zip/register.go
return &pooledFlateReader{fr: fr} } type pooledFlateReader struct { mu sync.Mutex // guards Close and Read fr io.ReadCloser } func (r *pooledFlateReader) Read(p []byte) (n int, err error) { r.mu.Lock() defer r.mu.Unlock() if r.fr == nil { return 0, errors.New("Read after Close") } return r.fr.Read(p) } func (r *pooledFlateReader) Close() error { r.mu.Lock() defer r.mu.Unlock() var err error
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Fri Oct 13 18:36:46 GMT 2023 - 3.7K bytes - Viewed (0) -
src/bytes/boundary_test.go
import ( . "bytes" "syscall" "testing" ) // This file tests the situation where byte operations are checking // data very near to a page boundary. We want to make sure those // operations do not read across the boundary and cause a page // fault where they shouldn't. // These tests run only on linux. The code being tested is // not OS-specific, so it does not need to be tested on all // operating systems.
Go - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Thu Nov 30 20:05:58 GMT 2023 - 2.8K bytes - Viewed (0) -
.github/CODE_OF_CONDUCT.md
# Code of Conduct
Plain Text - Registered: Tue May 07 11:14:38 GMT 2024 - Last Modified: Mon Nov 13 16:48:04 GMT 2017 - 95 bytes - Viewed (0) -
src/bytes/reader.go
// The result is unaffected by any method calls except [Reader.Reset]. 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 }
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) -
.github/PULL_REQUEST_TEMPLATE
Plain Text - Registered: Tue May 07 11:14:38 GMT 2024 - Last Modified: Wed Feb 21 02:07:46 GMT 2018 - 1.2K bytes - Viewed (0) -
CONTRIBUTING.md
3. What did you do? 4. What did you expect to see? 5. What did you see instead? For change proposals, see [Proposing Changes To Go](https://go.dev/s/proposal-process). ## Contributing code Please read the [Contribution Guidelines](https://golang.org/doc/contribute.html) before sending patches. Unless otherwise noted, the Go source files are distributed under
Plain Text - Registered: Tue May 07 11:14:38 GMT 2024 - Last Modified: Wed Mar 29 22:00:27 GMT 2023 - 1.3K bytes - Viewed (0) -
src/cmd/cgo/internal/swig/testdata/stdio/main.go
// as expected. f := Fopen("main.go", "r") if f.Swigcptr() == 0 { fatal("fopen failed") } if Fgetc(f) != '/' || Fgetc(f) != '/' || Fgetc(f) != ' ' || Fgetc(f) != 'C' { fatal("read unexpected characters") } if Fclose(f) != 0 { fatal("fclose failed") } println("OK") } func fatal(f string, args ...any) { fmt.Fprintln(os.Stderr, fmt.Sprintf(f, args...)) os.Exit(1)
Go - Registered: Tue Apr 23 11:13:09 GMT 2024 - Last Modified: Fri May 12 12:00:07 GMT 2023 - 975 bytes - Viewed (0) -
lib/time/README
For more information, see https://www.iana.org/time-zones ftp://ftp.iana.org/tz/code/tz-link.html https://datatracker.ietf.org/doc/html/rfc6557
Plain Text - Registered: Tue Apr 30 11:13:12 GMT 2024 - Last Modified: Sun Aug 15 02:18:46 GMT 2021 - 390 bytes - Viewed (0)