Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 28 for passed (0.17 sec)

  1. src/cmd/cgo/godefs.go

    // semicolon at each newline, so we can replace newline with semicolon.
    // However, we can't do that in cases where the lexer would not insert
    // a semicolon. We only have to worry about cases that can occur in an
    // expression passed through gofmt, which means composite literals and
    // (due to the printer possibly inserting newlines because of position
    // information) operators.
    var gofmtLineReplacer = strings.NewReplacer(
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Thu Sep 08 14:33:35 GMT 2022
    - 4.5K bytes
    - Viewed (0)
  2. src/cmd/cgo/internal/swig/testdata/stdio/main.go

    // license that can be found in the LICENSE file.
    
    // This file is here just to cause problems.
    // main.swig turns into a file also named main.go.
    // Make sure cmd/go keeps them separate
    // when both are passed to cgo.
    
    package main
    
    //int F(void) { return 1; }
    import "C"
    import (
    	"fmt"
    	"os"
    )
    
    func F() int { return int(C.F()) }
    
    func main() {
    	if x := int(C.F()); x != 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)
  3. src/cmd/cgo/internal/test/callback_c.c

    }
    
    int
    returnAfterGrowFromGo(void)
    {
    	extern int goReturnVal(void);
    	return goReturnVal();
    }
    
    void
    callGoWithString(void)
    {
    	extern void goWithString(GoString);
    	const char *str = "string passed from C to Go";
    	goWithString((GoString){str, strlen(str)});
    C
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Fri May 12 12:00:02 GMT 2023
    - 933 bytes
    - Viewed (0)
  4. src/cmd/cgo/doc.go

    pointers, depending on the element types. All the discussion below
    about Go pointers applies not just to pointer types, but also to other
    types that include Go pointers.
    
    All Go pointers passed to C must point to pinned Go memory. Go pointers
    passed as function arguments to C functions have the memory they point to
    implicitly pinned for the duration of the call. Go memory reachable from
    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)
  5. src/bytes/buffer.go

    	opReadRune1 readOp = 1  // Read rune of size 1.
    	opReadRune2 readOp = 2  // Read rune of size 2.
    	opReadRune3 readOp = 3  // Read rune of size 3.
    	opReadRune4 readOp = 4  // Read rune of size 4.
    )
    
    // ErrTooLarge is passed to panic if memory cannot be allocated to store data in a buffer.
    var ErrTooLarge = errors.New("bytes.Buffer: too large")
    var errNegativeRead = errors.New("bytes.Buffer: reader returned negative count from Read")
    
    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)
  6. src/cmd/asm/internal/arch/arm.go

    		return true
    	}
    	return false
    }
    
    // MCR is not defined by the obj/arm; instead we define it privately here.
    // It is encoded as an MRC with a bit inside the instruction word,
    // passed to arch.ARMMRCOffset.
    const aMCR = arm.ALAST + 1
    
    // IsARMMRC reports whether the op (as defined by an arm.A* constant) is
    // MRC or MCR.
    func IsARMMRC(op obj.As) bool {
    	switch op {
    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)
  7. doc/go1.17_spec.html

    <a href="#Order_of_evaluation">the usual order</a>.
    After they are evaluated, the parameters of the call are passed by value to the function
    and the called function begins execution.
    The return parameters of the function are passed by value
    back to the caller when the function returns.
    </p>
    
    <p>
    Calling a <code>nil</code> function value
    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)
  8. src/cmd/cgo/internal/test/callback.go

    			return 0
    		}
    		return i + f(i-1)
    	}
    	r = C.int(f(128))
    	return
    }
    
    // Test that C can pass in a Go string from a string constant.
    func testCallGoWithString(t *testing.T) {
    	C.callGoWithString()
    	want := "string passed from C to Go"
    	if stringFromGo != want {
    		t.Errorf("string passed through C is %s, want %s", stringFromGo, want)
    	}
    }
    
    var stringFromGo string
    
    //export goWithString
    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. doc/next/6-stdlib/99-minor/net/63116.md

    The [DNSError] type now wraps errors caused by timeouts or cancellation.
    For example, `errors.Is(someDNSErr, context.DeadlineExceedeed)`
    Plain Text
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Wed Apr 24 13:37:36 GMT 2024
    - 198 bytes
    - Viewed (0)
  10. src/archive/zip/reader_test.go

    	}
    
    	// negative size
    	_, err = NewReader(bytes.NewReader([]byte("foobar")), -1)
    	if err == nil {
    		t.Errorf("archive/zip.NewReader: expected error when negative size is passed")
    	}
    }
    
    func messWith(fileName string, corrupter func(b []byte)) (r io.ReaderAt, size int64) {
    	data, err := os.ReadFile(filepath.Join("testdata", fileName))
    	if err != nil {
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Wed Mar 27 18:23:49 GMT 2024
    - 55.3K bytes
    - Viewed (0)
Back to top