aboutsummaryrefslogtreecommitdiff
path: root/src/codegen/spirv.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/codegen/spirv.zig')
-rw-r--r--src/codegen/spirv.zig7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/codegen/spirv.zig b/src/codegen/spirv.zig
index ded73d6afd..e7e6ebdef3 100644
--- a/src/codegen/spirv.zig
+++ b/src/codegen/spirv.zig
@@ -959,12 +959,17 @@ const DeclGen = struct {
}
}
- fn constantAnonDeclRef(self: *DeclGen, ty: Type, decl_val: InternPool.Index) !IdRef {
+ fn constantAnonDeclRef(
+ self: *DeclGen,
+ ty: Type,
+ anon_decl: InternPool.Key.Ptr.Addr.AnonDecl,
+ ) !IdRef {
// TODO: Merge this function with constantDeclRef.
const mod = self.module;
const ip = &mod.intern_pool;
const ty_ref = try self.resolveType(ty, .direct);
+ const decl_val = anon_decl.val;
const decl_ty = ip.typeOf(decl_val).toType();
if (decl_val.toValue().getFunction(mod)) |func| {