[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Another example for syntactically lightweight closures
- From: David Given <dg@...>
- Date: Mon, 04 Feb 2008 18:53:22 +0000
Mark Hamburg wrote:
[...]
unwind_protect( io.close, f ) do
print( f:read( "*a" ) )
end
That's ambiguous --- the compiler can't distinguish this from:
unwing_protect(io.close, f);
do
print(f:read("*a"));
end;
OTOH it would be nice to have some way of avoiding the ugly end) after a
function closure in a parameter list.
--
David Given
dg@cowlark.com