From c2fa961b63cc32d9cecb8f33db465667c093f961 Mon Sep 17 00:00:00 2001 From: Andrew Kelley Date: Tue, 15 Jul 2025 19:40:59 -0700 Subject: [PATCH] update docs --- doc/langref/Assembly Syntax Explained.zig | 3 +-- doc/langref/inline_assembly.zig | 6 ++---- lib/docs/wasm/Walk.zig | 2 ++ 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/doc/langref/Assembly Syntax Explained.zig b/doc/langref/Assembly Syntax Explained.zig index e254d2ab35a90cb22fd1ab22e03dc64536c91c64..8141cd027123308feb0dbb3bdc3a917c0ee4e349 100644 --- a/doc/langref/Assembly Syntax Explained.zig +++ b/doc/langref/Assembly Syntax Explained.zig @@ -53,8 +53,7 @@ pub fn syscall1(number: usize, arg1: usize) usize { // memory locations - not only the memory pointed to by a declared indirect // output. In this example we list $rcx and $r11 because it is known the // kernel syscall does not preserve these registers. - : "rcx", "r11" - ); + : .{ .rcx = true, .r11 = true }); } // syntax diff --git a/doc/langref/inline_assembly.zig b/doc/langref/inline_assembly.zig index bd2841f0729ac1423c83200ffe1e54b1109d929f..dd13e61c3923cbb07008c3faf5533c259b020a47 100644 --- a/doc/langref/inline_assembly.zig +++ b/doc/langref/inline_assembly.zig @@ -15,8 +15,7 @@ pub fn syscall1(number: usize, arg1: usize) usize { : [ret] "={rax}" (-> usize), : [number] "{rax}" (number), [arg1] "{rdi}" (arg1), - : "rcx", "r11" - ); + : .{ .rcx = true, .r11 = true }); } pub fn syscall3(number: usize, arg1: usize, arg2: usize, arg3: usize) usize { @@ -26,8 +25,7 @@ pub fn syscall3(number: usize, arg1: usize, arg2: usize, arg3: usize) usize { [arg1] "{rdi}" (arg1), [arg2] "{rsi}" (arg2), [arg3] "{rdx}" (arg3), - : "rcx", "r11" - ); + : .{ .rcx = true, .r11 = true }); } // exe=succeed diff --git a/lib/docs/wasm/Walk.zig b/lib/docs/wasm/Walk.zig index 688fcbd00af2d7a718750d17fc6174068d400c5e..90df301f2235b1ed6cc7823baf1ad74b59e5d915 100644 --- a/lib/docs/wasm/Walk.zig +++ b/lib/docs/wasm/Walk.zig @@ -787,6 +787,8 @@ fn expr(w: *Walk, scope: *Scope, parent_decl: Decl.Index, node: Ast.Node.Index) try expr(w, scope, parent_decl, full.ast.template); }, + .asm_legacy => {}, + .builtin_call_two, .builtin_call_two_comma, .builtin_call, -- 2.54.0