Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for initialized (0.4 sec)

  1. doc/go_mem.html

    func main() {
    	go setup()
    	for g == nil {
    	}
    	print(g.msg)
    }
    </pre>
    
    <p>
    Even if <code>main</code> observes <code>g != nil</code> and exits its loop,
    there is no guarantee that it will observe the initialized
    value for <code>g.msg</code>.
    </p>
    
    <p>
    In all these examples, the solution is the same:
    use explicit synchronization.
    </p>
    
    <h2 id="badcompiler">Incorrect compilation</h2>
    
    <p>
    HTML
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Mon Mar 04 15:54:42 GMT 2024
    - 26.6K bytes
    - Viewed (0)
  2. doc/go1.17_spec.html

    <p>
    the variable <code>a</code> will be initialized after <code>b</code> but
    whether <code>x</code> is initialized before <code>b</code>, between
    <code>b</code> and <code>a</code>, or after <code>a</code>, and
    thus also the moment at which <code>sideEffect()</code> is called (before
    or after <code>x</code> is initialized) is not specified.
    </p>
    
    <p>
    Variables may also be initialized using functions named <code>init</code>
    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)
  3. doc/go_spec.html

    <p>
    the variable <code>a</code> will be initialized after <code>b</code> but
    whether <code>x</code> is initialized before <code>b</code>, between
    <code>b</code> and <code>a</code>, or after <code>a</code>, and
    thus also the moment at which <code>sideEffect()</code> is called (before
    or after <code>x</code> is initialized) is not specified.
    </p>
    
    <p>
    Variables may also be initialized using functions named <code>init</code>
    HTML
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Fri Apr 26 00:39:16 GMT 2024
    - 279.6K bytes
    - Viewed (0)
  4. doc/asm.html

    At the start of the function, the arguments are assumed
    to be initialized but the results are assumed uninitialized.
    If the results will hold live pointers during a call instruction,
    the function should start by zeroing the results and then
    executing the pseudo-instruction <code>GO_RESULTS_INITIALIZED</code>.
    This instruction records that the results are now initialized
    and should be scanned during stack movement and garbage collection.
    HTML
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Tue Nov 28 19:15:27 GMT 2023
    - 36.3K bytes
    - Viewed (0)
Back to top