Browse Source

fixed anonymous object parse bug.

Nicolas Cannasse 20 years ago
parent
commit
f0e3223dfa
1 changed files with 1 additions and 1 deletions
  1. 1 1
      parser.ml

+ 1 - 1
parser.ml

@@ -241,7 +241,7 @@ and parse_class_herit = parser
 and block1 = parser
 and block1 = parser
 	| [< '(Const (Ident name),p); s >] ->
 	| [< '(Const (Ident name),p); s >] ->
 		(match s with parser
 		(match s with parser
-		| [< '(DblDot,_); e = expr; l = psep Comma parse_obj_decl; _ = popt comma >] -> EObjectDecl ((name,e) :: l)
+		| [< '(DblDot,_); e = expr; l = plist parse_obj_decl; _ = popt comma >] -> EObjectDecl ((name,e) :: l)
 		| [< e = expr_next (EConst (Ident name),p); _ = semicolon; b = block >] -> EBlock (e :: b))
 		| [< e = expr_next (EConst (Ident name),p); _ = semicolon; b = block >] -> EBlock (e :: b))
 	| [< b = block >] -> EBlock b
 	| [< b = block >] -> EBlock b