Re: string.gsub accepting a callable userdata
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: string.gsub accepting a callable userdata
- From: Miles Bader <miles@...>
- Date: 2012年12月14日 23:18:06 +0900
Rena <hyperhacker@gmail.com> writes:
> I always thought Lua would benefit if it provided functions
> cancall() and canindex(), and libraries (especially the standard
> libraries) used them instead of checking for specific types.
Yeah, adding "type predicates" of some sort is an idea that's
suggested periodically when talking about type-handling; I think they
would be much cleaner in many cases than using the output of type().
But nothing's ever come of such suggestions... I'm crossing my fingers
for Lua 5.3... :]
-miles
--
Virtues, n. pl. Certain abstentions.