aboutsummaryrefslogtreecommitdiffstats
path: root/src/repl.cpp
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2009-10-14 00:00:58 +0000
committerDavid Robillard <d@drobilla.net>2009-10-14 00:00:58 +0000
commit6b89f484b7e41cab4a528a855b23be33d97dc474 (patch)
tree94760633554e377a08ae4e7504e522d7eedb769b /src/repl.cpp
parent1c851be2be3b2358e03fa7b2d6944d8bd1b0416d (diff)
downloadresp-6b89f484b7e41cab4a528a855b23be33d97dc474.tar.gz
resp-6b89f484b7e41cab4a528a855b23be33d97dc474.tar.bz2
resp-6b89f484b7e41cab4a528a855b23be33d97dc474.zip
Remove unnecessary cenv.compile wrapper.
Remove special treatment of symbols for compilation. Make CEnv::vals a <ASymbol*, CValue> map rather than <AST*, CValue> (only used for symbols). git-svn-id: http://svn.drobilla.net/resp/tuplr@214 ad02d1e2-f140-0410-9f75-f8b11f17cedd
Diffstat (limited to 'src/repl.cpp')
-rw-r--r--src/repl.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/repl.cpp b/src/repl.cpp
index fa08238..88885ea 100644
--- a/src/repl.cpp
+++ b/src/repl.cpp
@@ -97,7 +97,7 @@ eval(CEnv& cenv, const string& name, istream& is, bool execute)
// Compile all expressions into it
for (list< pair<AST*, AST*> >::const_iterator i = exprs.begin(); i != exprs.end(); ++i)
- val = cenv.compile(i->second);
+ val = i->second->compile(cenv);
// Finish compilation
cenv.engine()->finishFunction(cenv, f, resultT, val);
@@ -135,7 +135,7 @@ repl(CEnv& cenv)
try {
// Create function for this repl loop
f = cenv.engine()->startFunction(cenv, replFnName, resultT, ATuple(cursor));
- cenv.engine()->finishFunction(cenv, f, resultT, cenv.compile(result));
+ cenv.engine()->finishFunction(cenv, f, resultT, result->compile(cenv));
callPrintCollect(cenv, f, result, resultT, true);
} catch (Error& e) {
cenv.out << e.msg << endl;