Function gepStruct [src]
Prototype
pub fn gepStruct( self: *WipFunction, ty: Type, base: Value, index: usize, name: []const u8, ) Allocator.Error!Value
Parameters
self: *WipFunction
ty: Type
base: Value
index: usize
name: []const u8
Source
pub fn gepStruct(
self: *WipFunction,
ty: Type,
base: Value,
index: usize,
name: []const u8,
) Allocator.Error!Value {
assert(ty.isStruct(self.builder));
return self.gep(.inbounds, ty, base, &.{ .@"0", try self.builder.intValue(.i32, index) }, name);
}