fixed indexes when printing tables

git-svn-id: svn://anubis/anaglym/trunk@8 99a6e188-d820-4881-8870-2d33a10e2619
This commit is contained in:
Josh Holtrop 2009-09-14 02:43:44 +00:00
parent 689349d2b6
commit 356d3961f1

4
ag.cc
View File

@ -37,10 +37,10 @@ namespace ag
if (!first) if (!first)
cout << ", "; cout << ", ";
cout << '['; cout << '[';
ag_print_val(L, index + 1); ag_print_val(L, lua_gettop(L) - 1);
cout << ']'; cout << ']';
cout << " => "; cout << " => ";
ag_print_val(L, index + 2); ag_print_val(L, lua_gettop(L));
lua_pop(L, 1); lua_pop(L, 1);
} }