Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 42 for unstage (0.19 sec)

  1. src/cmd/cgo/doc.go

    	// #include <stdio.h>
    	// #include <stdlib.h>
    	//
    	// static void myprint(char* s) {
    	//   printf("%s\n", s);
    	// }
    	import "C"
    	import "unsafe"
    
    	func main() {
    		cs := C.CString("Hello from stdio")
    		C.myprint(cs)
    		C.free(unsafe.Pointer(cs))
    	}
    
    A few special functions convert between Go and C types
    by making copies of the data. In pseudo-Go definitions:
    
    	// Go string to C string
    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)
  2. src/arena/arena.go

    }
    
    //go:linkname runtime_arena_newArena
    func runtime_arena_newArena() unsafe.Pointer
    
    //go:linkname runtime_arena_arena_New
    func runtime_arena_arena_New(arena unsafe.Pointer, typ any) any
    
    // Mark as noescape to avoid escaping the slice header.
    //
    //go:noescape
    //go:linkname runtime_arena_arena_Slice
    func runtime_arena_arena_Slice(arena unsafe.Pointer, slice any, cap int)
    
    //go:linkname runtime_arena_arena_Free
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Wed Oct 12 20:23:36 GMT 2022
    - 4.3K bytes
    - Viewed (0)
  3. src/cmd/cgo/internal/swig/testdata/callback/main.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package main
    
    import (
    	"fmt"
    	"os"
    )
    
    func main() {
    	if len(os.Args) != 2 {
    		fatal("usage: callback testname")
    	}
    	switch os.Args[1] {
    	default:
    		fatal("unknown test %q", os.Args[1])
    	case "Call":
    		testCall()
    	case "Callback":
    		testCallback()
    	}
    	println("OK")
    }
    
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Fri May 12 12:00:07 GMT 2023
    - 1K bytes
    - Viewed (0)
  4. src/bootstrap.bash

    #
    # See also golang.org/x/build/cmd/genbootstrap, which is used
    # to generate bootstrap tgz files for builders.
    
    set -e
    
    if [ "$GOOS" = "" -o "$GOARCH" = "" ]; then
    	echo "usage: GOOS=os GOARCH=arch ./bootstrap.bash [-force]" >&2
    	exit 2
    fi
    
    forceflag=""
    if [ "$1" = "-force" ]; then
    	forceflag=-force
    	shift
    fi
    
    targ="../../go-${GOOS}-${GOARCH}-bootstrap"
    if [ -e $targ ]; then
    Shell Script
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Jan 20 17:52:26 GMT 2023
    - 2.3K bytes
    - Viewed (0)
  5. src/cmd/cgo/ast.go

    				if s, ok := spec.(*ast.ImportSpec); ok && s.Path.Value == `"C"` {
    					// Replace "C" with _ "unsafe", to keep program valid.
    					// (Deleting import statement or clause is not safe if it is followed
    					// in the source by an explicit semicolon.)
    					f.Edit.Replace(f.offset(s.Path.Pos()), f.offset(s.Path.End()), `_ "unsafe"`)
    				}
    			}
    		}
    	}
    
    	// Accumulate pointers to uses of C.x.
    	if f.Ref == nil {
    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)
  6. doc/go1.17_spec.html

    ExpressionStmt = Expression .
    </pre>
    
    <p>
    The following built-in functions are not permitted in statement context:
    </p>
    
    <pre>
    append cap complex imag len make new real
    unsafe.Add unsafe.Alignof unsafe.Offsetof unsafe.Sizeof unsafe.Slice
    </pre>
    
    <pre>
    h(x+y)
    f.Close()
    &lt;-ch
    (&lt;-ch)
    len("foo")  // illegal if len is the built-in function
    </pre>
    
    
    HTML
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Thu Apr 11 20:22:45 GMT 2024
    - 211.6K bytes
    - Viewed (0)
  7. misc/wasm/wasm_exec.js

    						delete this._inst;
    						delete this._values;
    						delete this._goRefCounts;
    						delete this._ids;
    						delete this._idPool;
    						this.exit(code);
    					},
    
    					// func wasmWrite(fd uintptr, p unsafe.Pointer, n int32)
    					"runtime.wasmWrite": (sp) => {
    						sp >>>= 0;
    						const fd = getInt64(sp + 8);
    						const p = getInt64(sp + 16);
    						const n = this.mem.getInt32(sp + 24, true);
    JavaScript
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Mon May 22 17:47:47 GMT 2023
    - 16.3K bytes
    - Viewed (1)
  8. src/cmd/cgo/internal/test/callback.go

    	// take a pointer.  We could pass an int if we felt like
    	// rewriting the C code.
    	C.callback(unsafe.Pointer(&i))
    
    	callbackMutex.Lock()
    	delete(callbackFuncs, i)
    	callbackMutex.Unlock()
    }
    
    //export goCallback
    func goCallback(p unsafe.Pointer) {
    	i := *(*int)(p)
    
    	callbackMutex.Lock()
    	f := callbackFuncs[i]
    	callbackMutex.Unlock()
    
    	if f == nil {
    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)
  9. api/go1.5.txt

    pkg go/types, type TypeAndValue struct, Value constant.Value
    pkg go/types, type TypeName struct
    pkg go/types, type Var struct
    pkg go/types, var Typ []*Basic
    pkg go/types, var Universe *Scope
    pkg go/types, var Unsafe *Package
    pkg html/template, method (*Template) Option(...string) *Template
    pkg image, const YCbCrSubsampleRatio410 = 5
    pkg image, const YCbCrSubsampleRatio410 YCbCrSubsampleRatio
    pkg image, const YCbCrSubsampleRatio411 = 4
    Plain Text
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Thu Jul 30 21:14:09 GMT 2015
    - 46.6K bytes
    - Viewed (0)
  10. src/cmd/asm/internal/flags/flags.go

    	(*m) = append(*m, val)
    	return nil
    }
    
    func Usage() {
    	fmt.Fprintf(os.Stderr, "usage: asm [options] file.s ...\n")
    	fmt.Fprintf(os.Stderr, "Flags:\n")
    	flag.PrintDefaults()
    	os.Exit(2)
    }
    
    func Parse() {
    	objabi.Flagparse(Usage)
    	if flag.NArg() == 0 {
    		flag.Usage()
    	}
    
    	// Flag refinement.
    	if *OutputFile == "" {
    		if flag.NArg() != 1 {
    			flag.Usage()
    		}
    		input := filepath.Base(flag.Arg(0))
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Tue Aug 22 19:18:23 GMT 2023
    - 2.8K bytes
    - Viewed (0)
Back to top