Debug: print interpreter address. Provide temporary dummy eval.
This commit is contained in:
parent
d0cb5639ec
commit
a76fe309dd
@ -15,13 +15,19 @@ using TheInterpreter = void ;
|
||||
|
||||
/// Create an interpreter object.
|
||||
TheInterpreter *cling_create(int argc, const char *argv[], const char* llvmdir) {
|
||||
return new cling::Interpreter(argc, argv, llvmdir);
|
||||
auto interp = new cling::Interpreter(argc, argv, llvmdir);
|
||||
printf("Interpreter @%p\n", interp);
|
||||
return interp;
|
||||
}
|
||||
|
||||
/// Evaluate a string of code. Returns 0 on success.
|
||||
int cling_eval_dummy(TheInterpreter *interpVP, const char *code) {
|
||||
printf("Called cling_eval_dummy\n");
|
||||
}
|
||||
/// Evaluate a string of code. Returns 0 on success.
|
||||
int cling_eval(TheInterpreter *interpVP, const char *code) {
|
||||
cling::Interpreter *interp = (cling::Interpreter *) interpVP;
|
||||
printf("Interpreter %s about to run \"%s\"\n", interp->getVersion(), code);
|
||||
printf("Interpreter @%p about to run \"%s\"\n", interp, code);
|
||||
cling::Value V;
|
||||
cling::Interpreter::CompilationResult Res = interp->evaluate(code, V);
|
||||
if (Res != cling::Interpreter::kSuccess)
|
||||
|
Loading…
Reference in New Issue
Block a user