[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Misc. request was: Faster tag methods
- From: rhq093s@...
- Date: Mon, 4 Mar 2002 19:58:32 +0100
On the subject of requests. Use of pattern matching in definitions of lua functions
would be nice. I was thinking of something of the order of the following:
function fib(0) return 1 end
function fib(1) return 1 end
function fib(n)
return fib(n-1)+fib(n-2)
end
print fib(5)
It's easy to write a preprocessor to do the transformation but it would be nice if it fit
into the base language.
MvH Dan Andersson