aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorkcbanner <kcbanner@gmail.com>2023-07-10 00:58:35 -0400
committerjacobly0 <jacobly0@users.noreply.github.com>2023-07-10 04:52:23 -0400
commit82a9d5d78d891b093c1755ecd5452b65619fdccf (patch)
treeb963c6136fb796f127fc0656ff715cad2f5ccc7d /src
parent874d2dd9f77b60a7eb6b2af3c34bb02783b0ec85 (diff)
downloadzig-82a9d5d78d891b093c1755ecd5452b65619fdccf.tar.gz
zig-82a9d5d78d891b093c1755ecd5452b65619fdccf.zip
type: update optionalReprIsPayload to handle inferred error sets
Diffstat (limited to 'src')
-rw-r--r--src/type.zig2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/type.zig b/src/type.zig
index e4ae2d2c35..e2e2171026 100644
--- a/src/type.zig
+++ b/src/type.zig
@@ -1869,7 +1869,7 @@ pub const Type = struct {
return switch (mod.intern_pool.indexToKey(ty.toIntern())) {
.opt_type => |child_type| child_type == .anyerror_type or switch (mod.intern_pool.indexToKey(child_type)) {
.ptr_type => |ptr_type| ptr_type.flags.size != .C and !ptr_type.flags.is_allowzero,
- .error_set_type => true,
+ .error_set_type, .inferred_error_set_type => true,
else => false,
},
.ptr_type => |ptr_type| ptr_type.flags.size == .C,