aboutsummaryrefslogtreecommitdiffstats
path: root/src/repl.cpp
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2010-12-04 23:21:09 +0000
committerDavid Robillard <d@drobilla.net>2010-12-04 23:21:09 +0000
commit8905a0e25858a047e0844c55ed8a025153ab25d9 (patch)
tree1ba8ae460e27d3c8f91db2178073e56ec1534dd5 /src/repl.cpp
parent1f488a7bd89d4cef07bd41ab22a290b0e230172d (diff)
downloadresp-8905a0e25858a047e0844c55ed8a025153ab25d9.tar.gz
resp-8905a0e25858a047e0844c55ed8a025153ab25d9.tar.bz2
resp-8905a0e25858a047e0844c55ed8a025153ab25d9.zip
More const-correctness (remove all use of const_cast).
git-svn-id: http://svn.drobilla.net/resp/resp@297 ad02d1e2-f140-0410-9f75-f8b11f17cedd
Diffstat (limited to 'src/repl.cpp')
-rw-r--r--src/repl.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/repl.cpp b/src/repl.cpp
index 7ef7ff3..4ea4d68 100644
--- a/src/repl.cpp
+++ b/src/repl.cpp
@@ -105,7 +105,7 @@ eval(CEnv& cenv, Cursor& cursor, istream& is, bool execute)
for (Parsed::const_iterator i = parsed.begin(); i != parsed.end(); ++i) {
const AST* l = resp_lift(cenv, lifted, *i);
if (l)
- lifted.push_back(const_cast<AST*>(l));
+ lifted.push_back(l);
}
if (cenv.args.find("-L") != cenv.args.end()) {
@@ -122,7 +122,7 @@ eval(CEnv& cenv, Cursor& cursor, istream& is, bool execute)
val = resp_compile(cenv, call);
} else {
assert(*i);
- ATuple* tup = (*i)->to_tuple();
+ const ATuple* tup = (*i)->to_tuple();
if (!tup || (tup->tup_len() > 0))
exprs.push_back(*i);
}
@@ -135,7 +135,7 @@ eval(CEnv& cenv, Cursor& cursor, istream& is, bool execute)
f = cenv.engine()->startFunction(cenv, "main", new ATuple(cursor), fnT);
// Compile expressions (other than function definitions) into it
- for (list<AST*>::const_iterator i = exprs.begin(); i != exprs.end(); ++i)
+ for (Code::const_iterator i = exprs.begin(); i != exprs.end(); ++i)
val = resp_compile(cenv, *i);
// Finish compilation