From c8c2a17e282c2cbf3c0edb1b756e16be58328331 Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Sat, 3 Mar 2012 01:17:21 -0600 Subject: Fixed invocation of lambda expressions foo = x, y, z -> print(x, y, z) foo(1, 2, 3) However, this still does not work: (x, y, z -> print(x, y, z))(1, 2, 3) --- src/op.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/op.cc') diff --git a/src/op.cc b/src/op.cc index 8e9df812..bd2cc32f 100644 --- a/src/op.cc +++ b/src/op.cc @@ -288,7 +288,7 @@ value_t expr_t::op_t::calc(scope_t& scope, ptr_op_t * locus, const int depth) } case O_LAMBDA: { - call_scope_t& call_args(downcast(scope)); + call_scope_t& call_args(find_scope(scope, true)); std::size_t args_count(call_args.size()); std::size_t args_index(0); symbol_scope_t call_scope(call_args); -- cgit v1.2.3