================
@@ -453,6 +450,9 @@ Interpreter::create(std::unique_ptr<CompilerInstance> CI, 
JITConfig Config) {
     }
   }
 
+  llvm::Error Err = llvm::Error::success();
+  std::unique_ptr<llvm::orc::LLJITBuilder> JB;
+
----------------
anutosh491 wrote:

No 2 : 

If we end up returning an error through maybe line 437 or line 446, that would 
make the whole session crash with 
```
Program aborted due to an unhandled Error:
Error value was Success. (Note: Success values must still be checked prior to 
being destroyed).
Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH 
or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it):
0  clang-repl 0x0000555559e2a302 llvm::sys::PrintStackTrace(llvm::raw_ostream&, 
int) + 88
1  clang-repl 0x0000555559e2a77f
2  clang-repl 0x0000555559e27973 llvm::sys::RunSignalHandlers() + 150
3  clang-repl 0x0000555559e29b2a
4  libc.so.6  0x00007ffff7951520
5  libc.so.6  0x00007ffff79a59fc pthread_kill + 300
6  libc.so.6  0x00007ffff7951476 raise + 22
7  libc.so.6  0x00007ffff79377f3 abort + 211
8  clang-repl 0x0000555559d44d3f
9  clang-repl 0x000055555695e278
10 clang-repl 0x000055555695e1a6
11 clang-repl 0x000055555a31bc40 
clang::Interpreter::create(std::unique_ptr<clang::CompilerInstance, 
std::default_delete<clang::CompilerInstance>>, clang::Interpreter::JITConfig) + 
2178
12 clang-repl 0x000055555695a532 main + 2822
13 libc.so.6  0x00007ffff7938d90
14 libc.so.6  0x00007ffff7938e40 __libc_start_main + 128
15 clang-repl 0x00005555569588a5 _start + 37
Aborted (core dumped)
```
Cause we are defining an error having value success at the top and not handling 
it !

https://github.com/llvm/llvm-project/pull/165852
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to