DoxigAlpha

copyAtomicLoad

Function parameters

Parameters

#
dest:*align(@alignOf(usize)) [Node.max_name_len]u8
src:*align(@alignOf(usize)) const [Node.max_name_len]u8

Type definitions in this namespace

Types

#
Node
Represents one unit of progress.

Initializes a global Progress instance.

Functions

#
start
Initializes a global Progress instance.
lockStdErr
Allows the caller to freely write to stderr until `unlockStdErr` is called.
lockStderrWriter
Allows the caller to freely write to the returned `Writer`,

= switch (builtin.os.tag) { .wasi, .freestanding, .windows => false, else => true, }

Values

#
have_ipc
= switch (builtin.os.tag) { .wasi, .freestanding, .windows => false, else => true, }

Source

Implementation

#
fn copyAtomicLoad(
    dest: *align(@alignOf(usize)) [Node.max_name_len]u8,
    src: *align(@alignOf(usize)) const [Node.max_name_len]u8,
) void {
    const chunked_len = @divExact(dest.len, @sizeOf(usize));
    const dest_chunked: *[chunked_len]usize = @ptrCast(dest);
    const src_chunked: *const [chunked_len]usize = @ptrCast(src);
    for (dest_chunked, src_chunked) |*d, *s| {
        d.* = @atomicLoad(usize, s, .monotonic);
    }
}