Re: require() parse error in 5.3.4/5.4.0-work2?
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: require() parse error in 5.3.4/5.4.0-work2?
- From: Andrew Gierth <andrew@...>
- Date: 2018年6月26日 13:15:49 +0100
>>>>> "Francisco" == Francisco Olarte <folarte@peoplecall.com> writes:
Francisco> Also, note checking for them in lua is difficult ( i.e., in
Francisco> f(a,b) is not easy to differentiate a call as f(1,nil) from
Francisco> f(1) , or f(1,2, nil) from f(1,2) ( I only know how to do it
Francisco> for the first case if I just declare f(...) or f(a,b,...)
Francisco> for the second and check table.unpack(...).n,
select('#', ...) is the official way to get the number of items in ...
if you don't otherwise need to table.pack it. (It's kind of irritating
that this takes a function call to do.)
--
Andrew.