| ... | @@ -491,9 +491,7 @@ pub const DeclGen = struct { | ... | @@ -491,9 +491,7 @@ pub const DeclGen = struct { |
| 491 | break :blk try self.spv.resolveType(SpvType.initPayload(&payload.base)); | 491 | break :blk try self.spv.resolveType(SpvType.initPayload(&payload.base)); |
| 492 | }, | 492 | }, |
| 493 | .Fn => blk: { | 493 | .Fn => blk: { |
| 494 | // We only support C-calling-convention functions for now, no varargs. | 494 | // TODO: Put this somewhere in Sema.zig |
| 495 | if (ty.fnCallingConvention() != .C) | | |
| 496 | return self.fail("Unsupported calling convention for SPIR-V", .{}); | | |
| 497 | if (ty.fnIsVarArgs()) | 495 | if (ty.fnIsVarArgs()) |
| 498 | return self.fail("VarArgs functions are unsupported for SPIR-V", .{}); | 496 | return self.fail("VarArgs functions are unsupported for SPIR-V", .{}); |
| 499 | | 497 | |