aboutsummaryrefslogtreecommitdiffstats
path: root/src/expand.cpp
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2012-12-23 05:31:15 +0000
committerDavid Robillard <d@drobilla.net>2012-12-23 05:31:15 +0000
commit67319bf0410196787c753225f46057bc7c94beec (patch)
tree572e8f8989a903fde8be784de5dddbaa1938ecfe /src/expand.cpp
parent0375a20786f1e6eba9d128889f700b22d447021c (diff)
downloadresp-67319bf0410196787c753225f46057bc7c94beec.tar.gz
resp-67319bf0410196787c753225f46057bc7c94beec.tar.bz2
resp-67319bf0410196787c753225f46057bc7c94beec.zip
Move towards standard Scheme syntax.
git-svn-id: http://svn.drobilla.net/resp/trunk@442 ad02d1e2-f140-0410-9f75-f8b11f17cedd
Diffstat (limited to 'src/expand.cpp')
-rw-r--r--src/expand.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/expand.cpp b/src/expand.cpp
index b50d627..0cbe118 100644
--- a/src/expand.cpp
+++ b/src/expand.cpp
@@ -41,7 +41,7 @@ expand_fn(PEnv& penv, const AST* exp, void* arg)
THROW_IF(++a == tup->end(), exp->loc, "Unexpected end of `fn' form");
THROW_IF(!(*a)->to_tuple(), (*a)->loc, "First argument of `fn' is not a list");
const ATuple* prot = (*a++)->to_tuple();
- List ret(new ATuple(penv.sym("fn"), NULL, exp->loc));
+ List ret(new ATuple(penv.sym("lambda"), NULL, exp->loc));
ret.push_back(prot);
while (a != tup->end())
ret.push_back(penv.expand(*a++));
@@ -67,7 +67,7 @@ expand_def(PEnv& penv, const AST* exp, void* arg)
argsExp.head->loc = exp->loc;
List fnExp;
- fnExp.push_back(penv.sym("fn"));
+ fnExp.push_back(penv.sym("lambda"));
fnExp.push_back(argsExp.head);
for (++i; i != tup->end(); ++i)
fnExp.push_back(*i);
@@ -94,9 +94,9 @@ PEnv::expand(const AST* exp)
THROW_IF(tup->empty(), exp->loc, "Call to empty list");
- if (is_form(tup, "def"))
+ if (is_form(tup, "define"))
return expand_def(*this, exp, NULL);
- else if (is_form(tup, "fn"))
+ else if (is_form(tup, "lambda"))
return expand_fn(*this, exp, NULL);
else
return expand_list(*this, tup);