aboutsummaryrefslogtreecommitdiff
path: root/src/type.zig
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2022-06-01 15:43:21 -0700
committerAndrew Kelley <andrew@ziglang.org>2022-06-01 15:43:21 -0700
commitb82cccc9e9b2230097f81fecec12ac0fdae97518 (patch)
treece1cf7a47b20f4dc2fc1c2d9f1033b396027a555 /src/type.zig
parentb095aa6986badc3b8c2255ad2c824ca4ea9959d9 (diff)
downloadzig-b82cccc9e9b2230097f81fecec12ac0fdae97518.tar.gz
zig-b82cccc9e9b2230097f81fecec12ac0fdae97518.zip
Sema: fix alignment of element ptr result type
Diffstat (limited to 'src/type.zig')
-rw-r--r--src/type.zig14
1 files changed, 0 insertions, 14 deletions
diff --git a/src/type.zig b/src/type.zig
index 94fcd0a96c..fc9841e28b 100644
--- a/src/type.zig
+++ b/src/type.zig
@@ -4177,20 +4177,6 @@ pub const Type = extern union {
};
}
- /// Returns the type of a pointer to an element.
- /// Asserts that the type is a pointer, and that the element type is indexable.
- /// For *[N]T, return *T
- /// For [*]T, returns *T
- /// For []T, returns *T
- /// Handles const-ness and address spaces in particular.
- pub fn elemPtrType(ptr_ty: Type, arena: Allocator, mod: *Module) !Type {
- return try Type.ptr(arena, mod, .{
- .pointee_type = ptr_ty.elemType2(),
- .mutable = ptr_ty.ptrIsMutable(),
- .@"addrspace" = ptr_ty.ptrAddressSpace(),
- });
- }
-
fn shallowElemType(child_ty: Type) Type {
return switch (child_ty.zigTypeTag()) {
.Array, .Vector => child_ty.childType(),