aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2000-05-12 15:12:04 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2000-05-12 15:12:04 -0300
commit843f84f4ce64bf43d8ebe568d8d1eeae9f484caf (patch)
tree3f90860642355cfdf934a75564d4203ee499f866
parentb803c0600eb20f3d4e47fd7a9ceecb096abcd3c6 (diff)
downloadlua-843f84f4ce64bf43d8ebe568d8d1eeae9f484caf.tar.gz
lua-843f84f4ce64bf43d8ebe568d8d1eeae9f484caf.tar.bz2
lua-843f84f4ce64bf43d8ebe568d8d1eeae9f484caf.zip
first element in a list constructor is not adjusted to one value.
-rw-r--r--bugs5
-rw-r--r--lparser.c4
2 files changed, 7 insertions, 2 deletions
diff --git a/bugs b/bugs
index b73c691e..0824384c 100644
--- a/bugs
+++ b/bugs
@@ -175,3 +175,8 @@ in the following platforms:
175Tue May 2 15:27:58 EST 2000 175Tue May 2 15:27:58 EST 2000
176>> `strfind' gets wrong subject length when there is an offset 176>> `strfind' gets wrong subject length when there is an offset
177(by Jon Kleiser; since 4.0a) 177(by Jon Kleiser; since 4.0a)
178
179** lparser.c
180Fri May 12 15:11:12 EST 2000
181>> first element in a list constructor is not adjusted to one value
182(by Tomas; since 4.0a)
diff --git a/lparser.c b/lparser.c
index 42cee394..9691f4d2 100644
--- a/lparser.c
+++ b/lparser.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lparser.c,v 1.84 2000/05/08 18:46:34 roberto Exp roberto $ 2** $Id: lparser.c,v 1.85 2000/05/10 16:33:20 roberto Exp roberto $
3** LL(1) Parser and code generator for Lua 3** LL(1) Parser and code generator for Lua
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -653,7 +653,7 @@ static void constructor_part (LexState *ls, Constdesc *cd) {
653 cd->k = 1; /* record */ 653 cd->k = 1; /* record */
654 } 654 }
655 else { 655 else {
656 luaK_tostack(ls, &v, 0); 656 luaK_tostack(ls, &v, 1);
657 cd->n = listfields(ls); 657 cd->n = listfields(ls);
658 cd->k = 0; /* list */ 658 cd->k = 0; /* list */
659 } 659 }