authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-02-18 17:41:55-05:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-02-18 17:41:55-05:00
log8922008dec5d631da0305527f670fb34852dfee7
tree01d5af0a8d4205e36ecad13d7c18273f3b87991a
parent28bf768883d2411d4cd75582d396d465ab6a54b2
signaturelock-open Commit is signed but in an unrecognized format.

docs: note top level declarations are order-independent

closes #1244

1 files changed, 3 insertions(+), 6 deletions(-)

doc/langref.html.in+3-6
......@@ -243,8 +243,9 @@ const Timestamp = struct {
243243 {#header_close#}
244244 {#header_open|Values#}
245245 {#code_begin|exe|values#}
246const std = @import("std");
246// Top-level declarations are order-independent:
247247const warn = std.debug.warn;
248const std = @import("std");
248249const os = std.os;
249250const assert = std.debug.assert;
250251
......@@ -6745,11 +6746,7 @@ pub fn build(b: *Builder) void {
67456746 {#header_open|Single Threaded Builds#}
67466747 <p>Zig has a compile option <code>--single-threaded</code> which has the following effects:
67476748 <ul>
6748 <li>{#link|@atomicLoad#} is emitted as a normal load.</li>
6749 <li>{#link|@atomicRmw#} is emitted as a normal memory load, modify, store.</li>
6750 <li>{#link|@fence#} becomes a no-op.</li>
6751 <li>Variables which have Thread Local Storage instead become globals. TODO thread local variables
6752 are not implemented yet.</li>
6749 <li>Variables which have Thread Local Storage instead become globals.</li>
67536750 <li>The overhead of {#link|Coroutines#} becomes equivalent to function call overhead.
67546751 TODO: please note this will not be implemented until the upcoming Coroutine Rewrite</li>
67556752 <li>The {#syntax#}@import("builtin").single_threaded{#endsyntax#} becomes {#syntax#}true{#endsyntax#}