aboutsummaryrefslogtreecommitdiff
path: root/ltablib.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2002-06-05 13:59:21 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2002-06-05 13:59:21 -0300
commit6dd0b6c62bd0016f456676c335308ebdfe6ce05d (patch)
treed3aff12bea204d33ade6e3481206ecffc8720f4c /ltablib.c
parentfa233012511e42740cb3ed12d553ad8f0a8e49d2 (diff)
downloadlua-6dd0b6c62bd0016f456676c335308ebdfe6ce05d.tar.gz
lua-6dd0b6c62bd0016f456676c335308ebdfe6ce05d.tar.bz2
lua-6dd0b6c62bd0016f456676c335308ebdfe6ce05d.zip
details
Diffstat (limited to 'ltablib.c')
-rw-r--r--ltablib.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ltablib.c b/ltablib.c
index a5e9148d..070569de 100644
--- a/ltablib.c
+++ b/ltablib.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ltablib.c,v 1.2 2002/04/12 19:57:29 roberto Exp roberto $ 2** $Id: ltablib.c,v 1.3 2002/05/02 17:12:27 roberto Exp roberto $
3** Library for Table Manipulation 3** Library for Table Manipulation
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -204,7 +204,7 @@ static int luaB_sort (lua_State *L) {
204 int n; 204 int n;
205 luaL_check_type(L, 1, LUA_TTABLE); 205 luaL_check_type(L, 1, LUA_TTABLE);
206 n = lua_getn(L, 1); 206 n = lua_getn(L, 1);
207 if (!lua_isnone(L, 2)) /* is there a 2nd argument? */ 207 if (!lua_isnoneornil(L, 2)) /* is there a 2nd argument? */
208 luaL_check_type(L, 2, LUA_TFUNCTION); 208 luaL_check_type(L, 2, LUA_TFUNCTION);
209 lua_settop(L, 2); /* make sure there is two arguments */ 209 lua_settop(L, 2); /* make sure there is two arguments */
210 auxsort(L, 1, n); 210 auxsort(L, 1, n);