Skip to content

Commit

Permalink
stage2: clear err_msg after it has been added to module.failed_decls
Browse files Browse the repository at this point in the history
  • Loading branch information
FireFox317 committed Jan 3, 2021
1 parent 0ed04aa commit a5dab15
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/llvm_backend.zig
Expand Up @@ -271,6 +271,7 @@ pub const LLVMIRModule = struct {
error.CodegenFail => {
decl.analysis = .codegen_failure;
try module.failed_decls.put(module.gpa, decl, self.err_msg.?);
self.err_msg = null;
return;
},
else => |e| return e,
Expand Down

0 comments on commit a5dab15

Please sign in to comment.