Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 1,411 for gostringw (0.16 sec)

  1. 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)
  2. 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)
  3. src/runtime/os_windows.go

    		if p[i] == 0 {
    			// empty string marks the end
    			if i == from {
    				break
    			}
    			from = i + 1
    			n++
    		}
    	}
    	envs = make([]string, n)
    
    	for i := range envs {
    		envs[i] = gostringw(&p[0])
    		for p[0] != 0 {
    			p = p[1:]
    		}
    		p = p[1:] // skip nil byte
    	}
    
    	stdcall1(_FreeEnvironmentStringsW, uintptr(strings))
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 26 22:55:25 UTC 2024
    - 41.5K bytes
    - Viewed (0)
  4. 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)
  5. 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)
  6. test/fixedbugs/issue65808.go

    type (
    	stringer  struct{}
    	stringers [2]stringer
    	foo       struct {
    		stringers
    	}
    )
    
    func (stringer) String() string  { return "" }
    func toString(s Stringer) string { return s.String() }
    
    func (v stringers) toStrings() []string {
    	return []string{toString(v[0]), toString(v[1])}
    }
    
    func main() {
    	_ = stringers{}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat Mar 02 14:01:52 UTC 2024
    - 562 bytes
    - Viewed (0)
  7. src/cmd/cgo/out.go

    typedef struct { const char *p; intgo n; } _GoString_;
    typedef struct { char *p; intgo n; intgo c; } _GoBytes_;
    _GoString_ GoString(char *p);
    _GoString_ GoStringN(char *p, int l);
    _GoBytes_ GoBytes(void *p, int n);
    char *CString(_GoString_);
    void *CBytes(_GoBytes_);
    void *_CMalloc(size_t);
    
    __attribute__ ((unused))
    static size_t _GoStringLen(_GoString_ s) { return (size_t)s.n; }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 29 16:41:10 UTC 2024
    - 59.6K bytes
    - Viewed (0)
  8. src/cmd/vendor/github.com/ianlancetaylor/demangle/ast.go

    	}
    	return t
    }
    
    func (t *Trinary) GoString() string {
    	return t.goString(0, "")
    }
    
    func (t *Trinary) goString(indent int, field string) string {
    	return fmt.Sprintf("%*s%sTrinary:\n%s\n%s\n%s\n%s", indent, "", field,
    		t.Op.goString(indent+2, "Op: "),
    		t.First.goString(indent+2, "First: "),
    		t.Second.goString(indent+2, "Second: "),
    		t.Third.goString(indent+2, "Third: "))
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 31 19:48:28 UTC 2024
    - 105.8K bytes
    - Viewed (0)
  9. platforms/jvm/language-groovy/src/main/java/org/gradle/api/internal/tasks/compile/NormalizingGroovyCompiler.java

                }
            });
    
            spec.setSourceFiles(ImmutableSet.copyOf(filtered));
        }
    
        private void resolveNonStringsInCompilerArgs(GroovyJavaJointCompileSpec spec) {
            // in particular, this is about GStrings
            spec.getCompileOptions().setCompilerArgs(CollectionUtils.toStringList(spec.getCompileOptions().getCompilerArgs()));
        }
    
        private void logSourceFiles(GroovyJavaJointCompileSpec spec) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon Apr 22 14:04:39 UTC 2024
    - 4.6K bytes
    - Viewed (0)
  10. src/cmd/cgo/internal/test/test.go

    	}
    }
    
    // api
    
    const greeting = "hello, world"
    
    type testPair struct {
    	Name      string
    	Got, Want interface{}
    }
    
    var testPairs = []testPair{
    	{"GoString", C.GoString(C.greeting), greeting},
    	{"GoStringN", C.GoStringN(C.greeting, 5), greeting[:5]},
    	{"GoBytes", C.GoBytes(unsafe.Pointer(C.greeting), 5), []byte(greeting[:5])},
    }
    
    func testHelpers(t *testing.T) {
    	for _, pair := range testPairs {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 20 15:50:06 UTC 2024
    - 48.5K bytes
    - Viewed (0)
Back to top