aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2011-01-09 16:03:40 +0000
committerDavid Robillard <d@drobilla.net>2011-01-09 16:03:40 +0000
commit8f7ed82fdbfea13d9fce553dc42db5b8d33e4bd9 (patch)
tree4cd63e119126426ffee9388b20ee9824fc04b0c4
parent95f95b258ba6b6ddec3a1bd933815a124bebb8c2 (diff)
downloadresp-8f7ed82fdbfea13d9fce553dc42db5b8d33e4bd9.tar.gz
resp-8f7ed82fdbfea13d9fce553dc42db5b8d33e4bd9.tar.bz2
resp-8f7ed82fdbfea13d9fce553dc42db5b8d33e4bd9.zip
Set type of lifted closure component accesses.
git-svn-id: http://svn.drobilla.net/resp/trunk@404 ad02d1e2-f140-0410-9f75-f8b11f17cedd
-rw-r--r--src/lift.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lift.cpp b/src/lift.cpp
index e55bdfe..2d26ace 100644
--- a/src/lift.cpp
+++ b/src/lift.cpp
@@ -46,10 +46,12 @@ lift_symbol(CEnv& cenv, Code& code, const ASymbol* sym) throw()
* to the closure (the calling lift_fn will use cenv.liftStack.top()
* to construct the closure after the fn body has been lifted).
*/
- return tup(sym->loc, cenv.penv.sym("."),
+ const AST* dot = tup(sym->loc, cenv.penv.sym("."),
cenv.penv.sym("_me"),
new ALiteral<int32_t>(T_INT32, vars.index(sym) + 1, Cursor()),
NULL);
+ cenv.setType(dot, cenv.type(sym));
+ return dot;
}
}
return sym;