aboutsummaryrefslogtreecommitdiff
path: root/src/ir.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2020-03-06 15:55:18 -0500
committerAndrew Kelley <andrew@ziglang.org>2020-03-06 15:55:18 -0500
commit3dc8cb12e81dde268f558de1cf2c3d288bd1939f (patch)
treec4eb4cec5079034787bf09acb4e44ebdaa82fc2e /src/ir.cpp
parenteaccfffe56655ab11a382685886492e5b9b0865c (diff)
downloadzig-3dc8cb12e81dde268f558de1cf2c3d288bd1939f.tar.gz
zig-3dc8cb12e81dde268f558de1cf2c3d288bd1939f.zip
ir: remove pointless and misleading code in `@embedFile`
Diffstat (limited to 'src/ir.cpp')
-rw-r--r--src/ir.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/ir.cpp b/src/ir.cpp
index 56ba634189..ef20c663b7 100644
--- a/src/ir.cpp
+++ b/src/ir.cpp
@@ -25048,9 +25048,7 @@ static IrInstGen *ir_analyze_instruction_embed_file(IrAnalyze *ira, IrInstSrcEmb
}
}
- ZigType *result_type = get_array_type(ira->codegen,
- ira->codegen->builtin_types.entry_u8, buf_len(file_contents), nullptr);
- IrInstGen *result = ir_const(ira, &instruction->base.base, result_type);
+ IrInstGen *result = ir_const(ira, &instruction->base.base, nullptr);
init_const_str_lit(ira->codegen, result->value, file_contents);
return result;
}