aboutsummaryrefslogtreecommitdiff
path: root/src/ir.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/ir.cpp')
-rw-r--r--src/ir.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ir.cpp b/src/ir.cpp
index 75efd919e..9e67cd952 100644
--- a/src/ir.cpp
+++ b/src/ir.cpp
@@ -5457,7 +5457,7 @@ irAddr ir_build_addr(irProcedure *proc, AstNode *expr) {
Type *type = base_type(ir_type(base));
if (is_type_pointer(type)) {
- type = type_deref(type);
+ type = base_type(type_deref(type));
addr = base;
base = ir_emit_load(proc, base);
}