diff options
| author | Diego Nehab <diego.nehab@gmail.com> | 2013-04-17 19:13:28 -0700 |
|---|---|---|
| committer | Diego Nehab <diego.nehab@gmail.com> | 2013-04-17 19:13:28 -0700 |
| commit | 00435529bb9a3a6614e9934fe20c27ada3dc2283 (patch) | |
| tree | db1e6c023b75b19bb8d761c3d8df576cd6b4d5cd /samples/tinyirc.lua | |
| parent | d548a78e5516bcc85d44f1d419cf53c71d6dcd79 (diff) | |
| parent | 56893e9dcd1eeebffb42b227a2151e18d49bc370 (diff) | |
| download | luasocket-00435529bb9a3a6614e9934fe20c27ada3dc2283.tar.gz luasocket-00435529bb9a3a6614e9934fe20c27ada3dc2283.tar.bz2 luasocket-00435529bb9a3a6614e9934fe20c27ada3dc2283.zip | |
Merge pull request #32 from ideka/unstable
Use the length operator (#) instead of table.getn.
Diffstat (limited to 'samples/tinyirc.lua')
| -rw-r--r-- | samples/tinyirc.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/samples/tinyirc.lua b/samples/tinyirc.lua index e75851f..5babb7e 100644 --- a/samples/tinyirc.lua +++ b/samples/tinyirc.lua | |||
| @@ -31,7 +31,7 @@ function newset() | |||
| 31 | insert = function(set, value) | 31 | insert = function(set, value) |
| 32 | if not reverse[value] then | 32 | if not reverse[value] then |
| 33 | table.insert(set, value) | 33 | table.insert(set, value) |
| 34 | reverse[value] = table.getn(set) | 34 | reverse[value] = #set |
| 35 | end | 35 | end |
| 36 | end, | 36 | end, |
| 37 | remove = function(set, value) | 37 | remove = function(set, value) |
