aboutsummaryrefslogtreecommitdiff
path: root/src/ir.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <superjoe30@gmail.com>2017-12-23 21:20:38 -0500
committerAndrew Kelley <superjoe30@gmail.com>2017-12-23 22:14:35 -0500
commit9dae796fe3bd08c4e636f09d1849f6ce2879a50b (patch)
treeea58c1305b9fbac2199f3dc1c60afd39290e9391 /src/ir.cpp
parent79c2ceb2d59af1f84edcc7a5a683ecf38dfb1bf6 (diff)
downloadzig-9dae796fe3bd08c4e636f09d1849f6ce2879a50b.tar.gz
zig-9dae796fe3bd08c4e636f09d1849f6ce2879a50b.zip
translate-c: set up debug scope for translated functions
Diffstat (limited to 'src/ir.cpp')
-rw-r--r--src/ir.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/ir.cpp b/src/ir.cpp
index a0f5a9be47..8698456379 100644
--- a/src/ir.cpp
+++ b/src/ir.cpp
@@ -14051,6 +14051,8 @@ static TypeTableEntry *ir_analyze_instruction_c_import(IrAnalyze *ira, IrInstruc
child_import->package = new_anonymous_package();
child_import->package->package_table.put(buf_create_from_str("builtin"), ira->codegen->compile_var_package);
child_import->package->package_table.put(buf_create_from_str("std"), ira->codegen->std_package);
+ child_import->di_file = ZigLLVMCreateFile(ira->codegen->dbuilder,
+ buf_ptr(buf_create_from_str("cimport.h")), buf_ptr(buf_create_from_str(".")));
ZigList<ErrorMsg *> errors = {0};