Re: Infinity as index
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: Infinity as index
- From: Roberto Ierusalimschy <roberto@...>
- Date: 2014年4月23日 11:12:23 -0300
> IMHO it is a bug that tbl[inf] and tbl[-inf] does not work.
?
> Lua 5.0.3 Copyright (C) 1994-2006 Tecgraf, PUC-Rio
> inf = 1/0
> tbl = {[inf] = 10, [-inf] = -20}
> print(tbl[inf])
10
> print(tbl[-inf])
-20
> Too late for Lua 5.1, but this could still make the final Lua 5.2
> release.
??
-- Roberto