Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 64 for once (0.16 sec)

  1. src/arena/arena.go

    // Arenas are useful for improving efficiency as they may be freed back to
    // the runtime manually, though any memory obtained from freed arenas must
    // not be accessed once that happens. An Arena is automatically freed once
    // it is no longer referenced, so it must be kept alive (see runtime.KeepAlive)
    // until any memory allocated from it is no longer needed.
    //
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Wed Oct 12 20:23:36 GMT 2022
    - 4.3K bytes
    - Viewed (0)
  2. src/cmd/cgo/internal/swig/swig_test.go

    		t.Skipf("could not parse 'go env CXX' output %q: %s", string(cxx), err)
    	}
    	if len(args) == 0 {
    		t.Skip("no C++ compiler")
    	}
    	testenv.MustHaveExecPath(t, string(args[0]))
    }
    
    var (
    	swigOnce sync.Once
    	haveSwig bool
    )
    
    func mustHaveSwig(t *testing.T) {
    	swigOnce.Do(func() {
    		mustHaveSwigOnce(t)
    		haveSwig = true
    	})
    	// The first call will skip t with a nice message. On later calls, we just skip.
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Fri May 12 12:00:07 GMT 2023
    - 3.7K bytes
    - Viewed (0)
  3. src/cmd/cgo/ast.go

    // a list of exported functions, and the actual AST, to be rewritten and
    // printed.
    func (f *File) ParseGo(abspath string, src []byte) {
    	// Two different parses: once with comments, once without.
    	// The printer is not good enough at printing comments in the
    	// right place when we start editing the AST behind its back,
    	// so we use ast1 to look for the doc comments on import "C"
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Wed Jun 07 16:54:27 GMT 2023
    - 14.3K bytes
    - Viewed (0)
  4. src/cmd/cgo/doc.go

    What happens at link time depends on whether the final binary is linked
    using the internal or external mode. If other packages are compiled in
    "external only" mode, then the final link will be an external one.
    Otherwise the link will be an internal one.
    
    The linking directives are used according to the kind of final link
    used.
    
    In internal mode, cmd/link itself processes all the host object files, in
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Sun Mar 31 09:02:45 GMT 2024
    - 42.1K bytes
    - Viewed (0)
  5. doc/go1.17_spec.html

    one iteration variable is permitted, otherwise there may be up to two.
    If the last iteration variable is the <a href="#Blank_identifier">blank identifier</a>,
    the range clause is equivalent to the same clause without that identifier.
    </p>
    
    <p>
    The range expression <code>x</code> is evaluated once before beginning the loop,
    with one exception: if at most one iteration variable is present and
    HTML
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Thu Apr 11 20:22:45 GMT 2024
    - 211.6K bytes
    - Viewed (0)
  6. doc/go_mem.html

    <p class="rule">
    The completion of a single call of <code>f()</code> from <code>once.Do(f)</code>
    is synchronized before the return of any call of <code>once.Do(f)</code>.
    </p>
    
    <p>
    In this program:
    </p>
    
    <pre>
    var a string
    var once sync.Once
    
    func setup() {
    	a = "hello, world"
    }
    
    func doprint() {
    	once.Do(setup)
    	print(a)
    }
    
    func twoprint() {
    	go doprint()
    HTML
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Mon Mar 04 15:54:42 GMT 2024
    - 26.6K bytes
    - Viewed (0)
  7. api/README

    Files in this directory are data for Go's API checker ("go tool api", in src/cmd/api).
    
    Each file is a list of API features, one per line.
    
    go1.txt (and similarly named files) are frozen once a version has been
    shipped. Each file adds new lines but does not remove any.
    
    except.txt lists features that may disappear without breaking true
    compatibility.
    
    Starting with go1.19.txt, each API feature line must end in "#nnnnn"
    Plain Text
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Wed Jan 31 19:22:50 GMT 2024
    - 1.2K bytes
    - Viewed (0)
  8. src/archive/zip/writer_test.go

    		for j := 0; j < 3; j++ {
    			w, _ := zw.CreateHeader(&FileHeader{
    				Name:   "foo",
    				Method: Deflate,
    			})
    			w.Write(bigBuf)
    		}
    		zw.Close()
    	}
    
    	b.ReportAllocs()
    	// Run once and then reset the timer.
    	// This effectively discards the very large initial flate setup cost,
    	// as well as the initialization of bigBuf.
    	runOnce(&bytes.Buffer{})
    	b.ResetTimer()
    
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Fri Sep 15 19:04:06 GMT 2023
    - 14.1K bytes
    - Viewed (0)
  9. misc/go_android_exec/main.go

    	// wait for sys.boot_completed.
    	if err := adb("wait-for-device", "exec-out", "while [[ -z $(getprop sys.boot_completed) ]]; do sleep 1; done;"); err != nil {
    		return 0, err
    	}
    
    	// Done once per make.bash.
    	if err := adbCopyGoroot(); err != nil {
    		return 0, err
    	}
    
    	// Prepare a temporary directory that will be cleaned up at the end.
    	// Binary names can conflict.
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Mon Aug 21 17:46:57 GMT 2023
    - 15.3K bytes
    - Viewed (0)
  10. src/cmd/asm/internal/arch/ppc64.go

    // IsPPC64CMP reports whether the op (as defined by an ppc64.A* constant) is
    // one of the CMP instructions that require special handling.
    func IsPPC64CMP(op obj.As) bool {
    	switch op {
    	case ppc64.ACMP, ppc64.ACMPU, ppc64.ACMPW, ppc64.ACMPWU, ppc64.AFCMPU:
    		return true
    	}
    	return false
    }
    
    // IsPPC64NEG reports whether the op (as defined by an ppc64.A* constant) is
    // one of the NEG-like instructions that require special handling.
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Wed Sep 07 20:53:33 GMT 2022
    - 2.2K bytes
    - Viewed (0)
Back to top