aboutsummaryrefslogtreecommitdiff
path: root/src/codegen.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <superjoe30@gmail.com>2016-04-18 15:47:21 -0700
committerAndrew Kelley <superjoe30@gmail.com>2016-04-18 15:47:21 -0700
commit5e33175517807c6e50fe66f8d6c65fc094c8e11a (patch)
tree004fc843be6c452f0c925915d080b8ab09432723 /src/codegen.cpp
parent832454f38b3ef635ee03fb54c382d8be02ac7c9e (diff)
downloadzig-5e33175517807c6e50fe66f8d6c65fc094c8e11a.tar.gz
zig-5e33175517807c6e50fe66f8d6c65fc094c8e11a.zip
add @embed_file builtin function
Diffstat (limited to 'src/codegen.cpp')
-rw-r--r--src/codegen.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/codegen.cpp b/src/codegen.cpp
index ddac9b72e0..0f2a63d3fc 100644
--- a/src/codegen.cpp
+++ b/src/codegen.cpp
@@ -507,6 +507,7 @@ static LLVMValueRef gen_builtin_fn_call_expr(CodeGen *g, AstNode *node) {
case BuiltinFnIdMaxValue:
case BuiltinFnIdMemberCount:
case BuiltinFnIdConstEval:
+ case BuiltinFnIdEmbedFile:
// caught by constant expression eval codegen
zig_unreachable();
case BuiltinFnIdCompileVar:
@@ -3896,6 +3897,7 @@ static void define_builtin_fns(CodeGen *g) {
create_builtin_fn_with_arg_count(g, BuiltinFnIdImport, "import", 1);
create_builtin_fn_with_arg_count(g, BuiltinFnIdCImport, "c_import", 1);
create_builtin_fn_with_arg_count(g, BuiltinFnIdErrName, "err_name", 1);
+ create_builtin_fn_with_arg_count(g, BuiltinFnIdEmbedFile, "embed_file", 1);
}
static void init(CodeGen *g, Buf *source_path) {