Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 75 for Tanghe (0.28 sec)

  1. src/cmd/cgo/internal/test/issue1435.go

    	fs, err := os.ReadDir(fmt.Sprintf("/proc/%d/task", pid))
    	if err != nil {
    		return fmt.Errorf("unable to find %d tasks: %v", pid, err)
    	}
    	expectedProc := fmt.Sprintf("Pid:\t%d", pid)
    	foundAThread := false
    	for _, f := range fs {
    		tf := fmt.Sprintf("/proc/%s/status", f.Name())
    		d, err := os.ReadFile(tf)
    		if err != nil {
    			// There are a surprising number of ways this
    			// can error out on linux.  We've seen all of
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Fri Jul 28 21:31:41 GMT 2023
    - 7.5K bytes
    - Viewed (0)
  2. src/archive/tar/strconv.go

    func isASCII(s string) bool {
    	for _, c := range s {
    		if c >= 0x80 || c == 0x00 {
    			return false
    		}
    	}
    	return true
    }
    
    // toASCII converts the input to an ASCII C-style string.
    // This is a best effort conversion, so invalid characters are dropped.
    func toASCII(s string) string {
    	if isASCII(s) {
    		return s
    	}
    	b := make([]byte, 0, len(s))
    	for _, c := range s {
    		if c < 0x80 && c != 0x00 {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Tue Aug 01 14:28:42 GMT 2023
    - 9K bytes
    - Viewed (0)
  3. src/cmd/cgo/internal/test/buildid_linux.go

    	if err != nil {
    		if os.IsNotExist(err) {
    			t.Skip("no /proc/self/exe")
    		}
    		t.Fatal("opening /proc/self/exe: ", err)
    	}
    	defer f.Close()
    
    	c := 0
    sections:
    	for i, s := range f.Sections {
    		if s.Type != elf.SHT_NOTE {
    			continue
    		}
    
    		d, err := s.Data()
    		if err != nil {
    			t.Logf("reading data of note section %d: %v", i, err)
    			continue
    		}
    
    		for len(d) > 0 {
    
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Fri May 12 12:00:02 GMT 2023
    - 1.7K bytes
    - Viewed (0)
  4. src/archive/tar/fuzz_test.go

    		// If we were unable to read anything out of the archive don't
    		// bother trying to roundtrip it.
    		if len(files) == 0 {
    			return
    		}
    
    		out := bytes.NewBuffer(nil)
    		w := NewWriter(out)
    		for _, f := range files {
    			if err := w.WriteHeader(f.header); err != nil {
    				t.Fatalf("unable to write previously parsed header: %s", err)
    			}
    			if _, err := w.Write(f.content); err != nil {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Thu Jan 13 18:06:33 GMT 2022
    - 2.2K bytes
    - Viewed (0)
  5. src/cmd/asm/internal/arch/arm.go

    	cond = strings.TrimPrefix(cond, ".")
    	if cond == "" {
    		return arm.C_SCOND_NONE, true
    	}
    	names := strings.Split(cond, ".")
    	bits := uint8(0)
    	for _, name := range names {
    		if b, present := ls[name]; present {
    			bits |= b
    			continue
    		}
    		if b, present := scond[name]; present {
    			bits = (bits &^ arm.C_SCOND) | b
    			continue
    		}
    		return 0, false
    	}
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Nov 18 17:59:44 GMT 2022
    - 6.1K bytes
    - Viewed (0)
  6. src/bytes/buffer.go

    func (b *Buffer) Truncate(n int) {
    	if n == 0 {
    		b.Reset()
    		return
    	}
    	b.lastRead = opInvalid
    	if n < 0 || n > b.Len() {
    		panic("bytes.Buffer: truncation out of range")
    	}
    	b.buf = b.buf[:b.off+n]
    }
    
    // Reset resets the buffer to be empty,
    // but it retains the underlying storage for use by future writes.
    // Reset is the same as [Buffer.Truncate](0).
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Oct 13 17:10:31 GMT 2023
    - 15.7K bytes
    - Viewed (0)
  7. misc/linkcheck/linkcheck.go

    	for _, m := range mv {
    		ref := m[1]
    		if strings.HasPrefix(ref, "/src/") {
    			continue
    		}
    		if !seen[ref] {
    			seen[ref] = true
    			links = append(links, m[1])
    		}
    	}
    	return
    }
    
    var idRx = regexp.MustCompile(`\bid=['"]?([^\s'">]+)`)
    
    func pageIDs(body string) (ids []string) {
    	mv := idRx.FindAllStringSubmatch(body, -1)
    	for _, m := range mv {
    		ids = append(ids, m[1])
    	}
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Wed Oct 06 15:53:04 GMT 2021
    - 3.9K bytes
    - Viewed (0)
  8. src/cmd/asm/internal/arch/arch.go

    	}
    
    	instructions := make(map[string]obj.As)
    	for i, s := range obj.Anames {
    		instructions[s] = obj.As(i)
    	}
    	for i, s := range ppc64.Anames {
    		if obj.As(i) >= obj.A_ARCHSPECIFIC {
    			instructions[s] = obj.As(i) + obj.ABasePPC64
    		}
    	}
    	// The opcodes generated by x/arch's ppc64map are listed in
    	// a separate slice, add them too.
    	for i, s := range ppc64.GenAnames {
    		instructions[s] = obj.As(i) + ppc64.AFIRSTGEN
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Tue Mar 21 06:51:28 GMT 2023
    - 21.3K bytes
    - Viewed (0)
  9. src/bytes/bytes_test.go

    	for i := 0; i <= 2*maxWnd; i++ {
    		for _, window := range windows {
    			if window > len(b[i:]) {
    				window = len(b[i:])
    			}
    			testCountWindow(i, window)
    			for j := 0; j < window; j++ {
    				b[i+j] = byte(0)
    			}
    		}
    	}
    	for i := 4096 - (maxWnd + 1); i < len(b); i++ {
    		for _, window := range windows {
    			if window > len(b[i:]) {
    				window = len(b[i:])
    			}
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Wed Jan 24 16:07:25 GMT 2024
    - 56.2K bytes
    - Viewed (0)
  10. src/cmd/asm/internal/asm/expr_test.go

    	{`'\x80'`, "illegal UTF-8 encoding for character constant"},
    	{"(23*4", "missing closing paren"},
    	{")23*4", "unexpected ) evaluating expression"},
    	{"18446744073709551616", "value out of range"},
    }
    
    func TestBadExpr(t *testing.T) {
    	for i, test := range badExprTests {
    		err := runBadTest(i, test, t)
    		if err == nil {
    			if test.error != "" {
    				t.Errorf("#%d: %q: expected error %q; got none", i, test.input, test.error)
    			}
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Tue Aug 29 07:48:38 GMT 2023
    - 3.2K bytes
    - Viewed (0)
Back to top