- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 3,418 for gostringw (0.21 sec)
-
src/runtime/string_test.go
var b []uint16 for _, c := range s { b = append(b, uint16(c)) if c != rune(uint16(c)) { t.Errorf("bad test: stringW can't handle >16 bit runes") } } b = append(b, 0) r := runtime.GostringW(b) if r != s { t.Errorf("gostringW(%v) = %s, want %s", b, r, s) } } } func TestLargeStringConcat(t *testing.T) { output := runTestProg(t, "testprog", "stringconcat")
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Dec 13 14:05:23 UTC 2022 - 13.3K bytes - Viewed (0) -
src/runtime/string.go
// This is exported via linkname to assembly in syscall (for Plan9) and cgo. // //go:linkname gostring func gostring(p *byte) string { l := findnull(p) if l == 0 { return "" } s, b := rawstring(l) memmove(unsafe.Pointer(&b[0]), unsafe.Pointer(p), uintptr(l)) return s } // internal_syscall_gostring is a version of gostring for internal/syscall/unix. //
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:17:26 UTC 2024 - 13.4K bytes - Viewed (0) -
test/fixedbugs/issue44739.go
func g(a T) { // test load of unaligned // 8 byte gostring, store // to unaligned static copy(a.y[:], gostring2) } func main() { var t1, t2 T // test copy to automatic storage, // load of unaligned gostring. copy(st.y[:], gostring2) copy(t1.y[:], st.y[:]) copy(t2.y[:], gostring3) // test initialization of params if !f(t1, 'a', t2) { // gostring1 added so it has a use fmt.Printf("FAIL: %s\n", gostring1)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Mar 10 19:33:23 UTC 2021 - 1.1K bytes - Viewed (0) -
src/runtime/export_test.go
func MemclrBytes(b []byte) { s := (*slice)(unsafe.Pointer(&b)) memclrNoHeapPointers(s.array, uintptr(s.len)) } const HashLoad = hashLoad // entry point for testing func GostringW(w []uint16) (s string) { systemstack(func() { s = gostringw(&w[0]) }) return } var Open = open var Close = closefd var Read = read var Write = write func Envs() []string { return envs }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 17:50:53 UTC 2024 - 46.1K bytes - Viewed (0) -
src/runtime/os_windows.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 26 22:55:25 UTC 2024 - 41.5K bytes - Viewed (0) -
src/vendor/golang.org/x/net/dns/dnsmessage/message.go
} return printUint16(uint16(c)) } // GoString implements fmt.GoStringer.GoString. func (c Class) GoString() string { if n, ok := classNames[c]; ok { return "dnsmessage." + n } return printUint16(uint16(c)) } // An OpCode is a DNS operation code. type OpCode uint16 // GoString implements fmt.GoStringer.GoString. func (o OpCode) GoString() string { return printUint16(uint16(o)) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Sat Mar 09 00:09:40 UTC 2024 - 69K bytes - Viewed (0) -
test/gcstring.go
Emmanuel Odeke <******@****.***> 1460323946 -0700
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 02 13:43:18 UTC 2016 - 872 bytes - Viewed (0) -
src/debug/macho/reloctype.go
GENERIC_RELOC_PB_LA_PTR RelocTypeGeneric = 3 GENERIC_RELOC_LOCAL_SECTDIFF RelocTypeGeneric = 4 GENERIC_RELOC_TLV RelocTypeGeneric = 5 ) func (r RelocTypeGeneric) GoString() string { return "macho." + r.String() } type RelocTypeX86_64 int const ( X86_64_RELOC_UNSIGNED RelocTypeX86_64 = 0 X86_64_RELOC_SIGNED RelocTypeX86_64 = 1 X86_64_RELOC_BRANCH RelocTypeX86_64 = 2
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Aug 14 18:45:40 UTC 2017 - 2.4K bytes - Viewed (0) -
src/cmd/cgo/doc.go
C.sizeof_struct_stat. A C function may be declared in the Go file with a parameter type of the special name _GoString_. This function may be called with an ordinary Go string value. The string length, and a pointer to the string contents, may be accessed by calling the C functions size_t _GoStringLen(_GoString_ s); const char *_GoStringPtr(_GoString_ s); These functions are only available in the preamble, not in other C
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 13 17:12:16 UTC 2024 - 42.2K bytes - Viewed (0) -
src/runtime/testdata/testprogcgo/deadlock.go
import ( "fmt" ) func init() { register("CgoPanicDeadlock", CgoPanicDeadlock) } type cgoError struct{} func (cgoError) Error() string { fmt.Print("") // necessary to trigger the deadlock return C.GoString(C.geterror()) } func CgoPanicDeadlock() { panic(cgoError{})
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Mar 01 23:34:33 UTC 2016 - 509 bytes - Viewed (0)