summaryrefslogtreecommitdiff
path: root/ltablib.c
diff options
context:
space:
mode:
Diffstat (limited to 'ltablib.c')
-rw-r--r--ltablib.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ltablib.c b/ltablib.c
index 9d4d5910..a5e9148d 100644
--- a/ltablib.c
+++ b/ltablib.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ltablib.c,v 1.1 2002/04/09 20:19:06 roberto Exp roberto $ 2** $Id: ltablib.c,v 1.2 2002/04/12 19:57:29 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*/
@@ -171,12 +171,12 @@ static void auxsort (lua_State *L, int l, int u) {
171 for (;;) { /* invariant: a[l..i] <= P <= a[j..u] */ 171 for (;;) { /* invariant: a[l..i] <= P <= a[j..u] */
172 /* repeat ++i until a[i] >= P */ 172 /* repeat ++i until a[i] >= P */
173 while (lua_rawgeti(L, 1, ++i), sort_comp(L, -1, -2)) { 173 while (lua_rawgeti(L, 1, ++i), sort_comp(L, -1, -2)) {
174 if (i>u) lua_error(L, "invalid order function for sorting"); 174 if (i>u) luaL_verror(L, "invalid order function for sorting");
175 lua_pop(L, 1); /* remove a[i] */ 175 lua_pop(L, 1); /* remove a[i] */
176 } 176 }
177 /* repeat --j until a[j] <= P */ 177 /* repeat --j until a[j] <= P */
178 while (lua_rawgeti(L, 1, --j), sort_comp(L, -3, -1)) { 178 while (lua_rawgeti(L, 1, --j), sort_comp(L, -3, -1)) {
179 if (j<l) lua_error(L, "invalid order function for sorting"); 179 if (j<l) luaL_verror(L, "invalid order function for sorting");
180 lua_pop(L, 1); /* remove a[j] */ 180 lua_pop(L, 1); /* remove a[j] */
181 } 181 }
182 if (j<i) { 182 if (j<i) {