aboutsummaryrefslogtreecommitdiff
path: root/src/link/Wasm.zig
diff options
context:
space:
mode:
authorLuuk de Gram <luuk@degram.dev>2022-06-23 16:20:20 +0200
committerLuuk de Gram <luuk@degram.dev>2022-06-24 08:12:17 +0200
commit7c87f9c828282aa12fb2d77c9c6a2318d83b8dff (patch)
treed1168ba85eca9ea505d901faecd97847b5bea76c /src/link/Wasm.zig
parent3868864695b41c2c94f585b9644d3ed3bda39708 (diff)
downloadzig-7c87f9c828282aa12fb2d77c9c6a2318d83b8dff.tar.gz
zig-7c87f9c828282aa12fb2d77c9c6a2318d83b8dff.zip
link:clarification & enable MachO getGlobalSymbol
This adds clarification to the getGlobalSymbol doc comments, as well as renames the `addExternFn` function for MachO to `getGlobalSymbol`. This function will now be called from 'src/link.zig' as well. Finally, this also enables compiling zig's libc using LLVM even though the `fno-LLVM` flag is given.
Diffstat (limited to 'src/link/Wasm.zig')
-rw-r--r--src/link/Wasm.zig3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/link/Wasm.zig b/src/link/Wasm.zig
index d10690142f..4357a588a1 100644
--- a/src/link/Wasm.zig
+++ b/src/link/Wasm.zig
@@ -864,7 +864,8 @@ pub fn lowerUnnamedConst(self: *Wasm, tv: TypedValue, decl_index: Module.Decl.In
return atom.sym_index;
}
-/// Returns the symbol index from the name of an intrinsic.
+/// Returns the symbol index from a symbol of which its flag is set global,
+/// such as an exported or imported symbol.
/// If the symbol does not yet exist, creates a new one symbol instead
/// and then returns the index to it.
pub fn getGlobalSymbol(self: *Wasm, name: []const u8) !u32 {