Skip to content
Unverified Commit 8082a002 authored by Jun Zhang's avatar Jun Zhang
Browse files

[CodeGen] Keep track of decls that were deferred and have been emitted.



This patch adds a new field called EmittedDeferredDecls in CodeGenModule
that keeps track of decls that were deferred and have been emitted.

The intention of this patch is to solve issues in the incremental c++,
we'll lose info of decls that are lazily emitted when we undo their
usage.

See example below:

clang-repl> inline int foo() { return 42;}
clang-repl> int bar = foo();
clang-repl> %undo
clang-repl> int baz = foo();
JIT session error: Symbols not found: [ _Z3foov ]
error: Failed to materialize symbols: { (main, { baz, $.incr_module_2.inits.0,
orc_init_func.incr_module_2 }) }

Signed-off-by: default avatarJun Zhang <jun@junz.org>

Differential Revision: https://reviews.llvm.org/D128782
parent b8d83e80
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment