aboutsummaryrefslogtreecommitdiff
path: root/src/link.zig
diff options
context:
space:
mode:
authormlugg <mlugg@mlugg.co.uk>2023-06-12 22:01:33 +0100
committerAndrew Kelley <andrew@ziglang.org>2023-06-12 14:22:19 -0700
commit415dbe93d44a5f86deecc1501185d6bfd34f80b4 (patch)
treeeb8e4da57a5eba70cd80dc48943a53631daac16a /src/link.zig
parent9e61ba19e9cda344aa2094e9a671d98076164163 (diff)
downloadzig-415dbe93d44a5f86deecc1501185d6bfd34f80b4.tar.gz
zig-415dbe93d44a5f86deecc1501185d6bfd34f80b4.zip
link: fix compile error with only-c
Diffstat (limited to 'src/link.zig')
-rw-r--r--src/link.zig3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/link.zig b/src/link.zig
index e43153f0b1..c184f7ed7c 100644
--- a/src/link.zig
+++ b/src/link.zig
@@ -562,10 +562,9 @@ pub const File = struct {
/// May be called before or after updateDeclExports for any given Decl.
pub fn updateFunc(base: *File, module: *Module, func_index: Module.Fn.Index, air: Air, liveness: Liveness) UpdateDeclError!void {
- const func = module.funcPtr(func_index);
if (build_options.only_c) {
assert(base.tag == .c);
- return @fieldParentPtr(C, "base", base).updateFunc(module, func, air, liveness);
+ return @fieldParentPtr(C, "base", base).updateFunc(module, func_index, air, liveness);
}
switch (base.tag) {
// zig fmt: off