[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677

mjs mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:07:31 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit 219ed0ac44aa3e0b46634e35087322d585eb801c
Author: mjs <mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Sun Nov 24 10:12:02 2002 +0000

    	- fixed 3095446 - Crash on AppleScript page due to very long argument list
    
            * kjs/grammar.y: Don't try to construct the argument list in the
    	right order, since that blows out the parser stack.
    	* kjs/nodes.cpp:
            (ArgumentsNode::ArgumentsNode): Instead reverse the argument list
    	here.
            * kjs/nodes.h: Make ArgumentsNode a friend of ArgumentListNode.
            * kjs/grammar.cpp: Updated from grammar.y.
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@2847 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/JavaScriptCore/ChangeLog b/JavaScriptCore/ChangeLog
index 5dddb55..b851b1c 100644
--- a/JavaScriptCore/ChangeLog
+++ b/JavaScriptCore/ChangeLog
@@ -1,3 +1,15 @@
+2002-11-24  Maciej Stachowiak  <mjs at apple.com>
+
+	- fixed 3095446 - Crash on AppleScript page due to very long argument list
+	
+        * kjs/grammar.y: Don't try to construct the argument list in the
+	right order, since that blows out the parser stack.
+	* kjs/nodes.cpp:
+        (ArgumentsNode::ArgumentsNode): Instead reverse the argument list
+	here.
+        * kjs/nodes.h: Make ArgumentsNode a friend of ArgumentListNode.
+        * kjs/grammar.cpp: Updated from grammar.y.
+
 2002-11-23  Maciej Stachowiak  <mjs at apple.com>
 
 	- completed Darin's mostly-fix for 3037795 - Resource use
diff --git a/JavaScriptCore/ChangeLog-2002-12-03 b/JavaScriptCore/ChangeLog-2002-12-03
index 5dddb55..b851b1c 100644
--- a/JavaScriptCore/ChangeLog-2002-12-03
+++ b/JavaScriptCore/ChangeLog-2002-12-03
@@ -1,3 +1,15 @@
+2002-11-24  Maciej Stachowiak  <mjs at apple.com>
+
+	- fixed 3095446 - Crash on AppleScript page due to very long argument list
+	
+        * kjs/grammar.y: Don't try to construct the argument list in the
+	right order, since that blows out the parser stack.
+	* kjs/nodes.cpp:
+        (ArgumentsNode::ArgumentsNode): Instead reverse the argument list
+	here.
+        * kjs/nodes.h: Make ArgumentsNode a friend of ArgumentListNode.
+        * kjs/grammar.cpp: Updated from grammar.y.
+
 2002-11-23  Maciej Stachowiak  <mjs at apple.com>
 
 	- completed Darin's mostly-fix for 3037795 - Resource use
diff --git a/JavaScriptCore/ChangeLog-2003-10-25 b/JavaScriptCore/ChangeLog-2003-10-25
index 5dddb55..b851b1c 100644
--- a/JavaScriptCore/ChangeLog-2003-10-25
+++ b/JavaScriptCore/ChangeLog-2003-10-25
@@ -1,3 +1,15 @@
+2002-11-24  Maciej Stachowiak  <mjs at apple.com>
+
+	- fixed 3095446 - Crash on AppleScript page due to very long argument list
+	
+        * kjs/grammar.y: Don't try to construct the argument list in the
+	right order, since that blows out the parser stack.
+	* kjs/nodes.cpp:
+        (ArgumentsNode::ArgumentsNode): Instead reverse the argument list
+	here.
+        * kjs/nodes.h: Make ArgumentsNode a friend of ArgumentListNode.
+        * kjs/grammar.cpp: Updated from grammar.y.
+
 2002-11-23  Maciej Stachowiak  <mjs at apple.com>
 
 	- completed Darin's mostly-fix for 3037795 - Resource use
diff --git a/JavaScriptCore/kjs/grammar.cpp b/JavaScriptCore/kjs/grammar.cpp
index 4d74305..256707f 100644
--- a/JavaScriptCore/kjs/grammar.cpp
+++ b/JavaScriptCore/kjs/grammar.cpp
@@ -255,7 +255,7 @@ static const short yyrhs[] = {     3,
      0,    12,    93,    96,     0,    93,     0,    12,    94,     0,
     93,    96,     0,    95,    96,     0,    95,    66,   114,    67,
      0,    95,    70,    58,     0,    62,    63,     0,    62,    97,
-    63,     0,   112,     0,   112,    68,    97,     0,    94,     0,
+    63,     0,   112,     0,    97,    68,   112,     0,    94,     0,
     95,     0,    98,     0,    98,    42,     0,    98,    43,     0,
     99,     0,    18,   100,     0,    17,   100,     0,    26,   100,
      0,    42,   100,     0,    59,   100,     0,    43,   100,     0,
@@ -318,22 +318,22 @@ static const short yyrline[] = { 0,
    180,   181,   182,   183,   186,   188,   189,   192,   194,   198,
    200,   203,   205,   208,   210,   214,   216,   217,   220,   222,
    223,   224,   225,   228,   230,   233,   235,   236,   237,   241,
-   243,   246,   249,   255,   257,   260,   262,   263,   266,   268,
-   269,   270,   271,   272,   273,   274,   275,   276,   277,   278,
-   281,   283,   284,   285,   288,   290,   291,   294,   296,   297,
-   298,   301,   303,   305,   307,   309,   311,   313,   317,   319,
-   320,   321,   322,   325,   327,   330,   332,   335,   337,   340,
-   342,   346,   348,   352,   354,   358,   360,   364,   366,   367,
-   368,   369,   370,   371,   372,   373,   374,   375,   376,   379,
-   381,   384,   386,   387,   388,   389,   390,   391,   392,   393,
-   394,   395,   396,   397,   398,   401,   403,   406,   408,   411,
-   414,   423,   425,   429,   431,   434,   438,   442,   445,   452,
-   454,   458,   460,   461,   464,   467,   470,   474,   480,   482,
-   485,   487,   491,   493,   500,   502,   506,   508,   516,   518,
-   522,   523,   529,   534,   539,   541,   545,   547,   550,   552,
-   555,   557,   560,   562,   565,   571,   575,   577,   578,   581,
-   585,   589,   592,   596,   598,   603,   605,   609,   612,   616,
-   619,   623,   626,   632,   634
+   243,   246,   248,   251,   253,   256,   258,   259,   262,   264,
+   265,   266,   267,   268,   269,   270,   271,   272,   273,   274,
+   277,   279,   280,   281,   284,   286,   287,   290,   292,   293,
+   294,   297,   299,   301,   303,   305,   307,   309,   313,   315,
+   316,   317,   318,   321,   323,   326,   328,   331,   333,   336,
+   338,   342,   344,   348,   350,   354,   356,   360,   362,   363,
+   364,   365,   366,   367,   368,   369,   370,   371,   372,   375,
+   377,   380,   382,   383,   384,   385,   386,   387,   388,   389,
+   390,   391,   392,   393,   394,   397,   399,   402,   404,   407,
+   410,   419,   421,   425,   427,   430,   434,   438,   441,   448,
+   450,   454,   456,   457,   460,   463,   466,   470,   476,   478,
+   481,   483,   487,   489,   496,   498,   502,   504,   512,   514,
+   518,   519,   525,   530,   535,   537,   541,   543,   546,   548,
+   551,   553,   556,   558,   561,   567,   571,   573,   574,   577,
+   581,   585,   588,   592,   594,   599,   601,   605,   608,   612,
+   615,   619,   622,   628,   630
 };
 #endif
 
@@ -473,39 +473,39 @@ static const short yypact[] = {   631,
 -32768,-32768,     7,-32768,   129,   -42,-32768,-32768,    18,   112,
 -32768,-32768,  1066,   230,  1066,-32768,  1066,  1066,   -45,   483,
    162,-32768,-32768,   705,-32768,-32768,    -6,   150,   176,    50,
-   220,   -37,   185,   212,-32768,   154,   850,   196,-32768,-32768,
--32768,-32768,   922,  1066,   224,-32768,  1066,   234,-32768,-32768,
+   220,   -37,   185,   212,-32768,   154,   850,   214,-32768,-32768,
+-32768,-32768,   922,  1066,   234,-32768,  1066,   237,-32768,-32768,
 -32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
 -32768,-32768,-32768,  1066,  1066,  1066,  1066,  1066,  1066,  1066,
   1066,  1066,  1066,  1066,  1066,  1066,  1066,  1066,  1066,  1066,
   1066,  1066,  1066,  1066,  1066,  1066,  1066,  1066,-32768,  1066,
--32768,-32768,-32768,-32768,   244,    87,   238,   225,-32768,-32768,
+-32768,-32768,-32768,-32768,   244,    87,   241,   226,-32768,-32768,
 -32768,-32768,-32768,  1066,-32768,-32768,   -24,-32768,-32768,-32768,
-    64,-32768,   243,   100,-32768,-32768,   103,   248,   121,   122,
-   124,-32768,-32768,   250,     0,   281,-32768,-32768,-32768,-32768,
-    35,  1066,-32768,-32768,    12,-32768,-32768,-32768,-32768,   252,
-   249,   223,-32768,   228,-32768,-32768,-32768,-32768,-32768,    71,
+    64,-32768,   248,   100,-32768,-32768,   103,   252,   121,   122,
+   124,-32768,-32768,   253,     0,   283,-32768,-32768,-32768,-32768,
+    35,  1066,-32768,-32768,    12,-32768,-32768,-32768,-32768,   181,
+-32768,   203,-32768,   223,-32768,-32768,-32768,-32768,-32768,    71,
     71,   -25,   -25,   -25,    38,    38,    38,    38,    38,    38,
-    82,    82,    82,    82,   239,   239,   239,    84,   133,   247,
--32768,   -15,   -41,  1066,  1066,-32768,-32768,   243,   181,   557,
--32768,   243,   260,   705,  1066,   705,   255,   705,   262,-32768,
--32768,   253,-32768,   994,-32768,  1066,-32768,-32768,  1066,  1066,
-   299,  1066,   190,   241,-32768,   243,-32768,   264,-32768,-32768,
-   307,   197,-32768,   323,-32768,-32768,   270,  1066,-32768,-32768,
--32768,-32768,   199,  1066,   259,   705,  1066,-32768,-32768,   705,
--32768,  1066,    23,   323,-32768,     0,-32768,   705,   200,  1066,
--32768,   274,-32768,   229,   275,-32768,   323,-32768,-32768,-32768,
-   705,   282,   705,   705,   705,   283,-32768,   705,-32768,-32768,
-   705,   705,-32768,-32768,-32768,   346,   349,-32768
+    82,    82,    82,    82,   239,   239,   239,    84,   133,   249,
+-32768,   -15,   -41,  1066,  1066,-32768,-32768,   248,   190,   557,
+-32768,   248,   259,   705,  1066,   705,   255,   705,   262,-32768,
+-32768,   254,-32768,   994,-32768,  1066,-32768,-32768,  1066,  1066,
+   298,  1066,   197,   245,-32768,   248,-32768,   260,-32768,-32768,
+   307,   199,-32768,   323,-32768,-32768,   270,  1066,-32768,-32768,
+-32768,-32768,   200,  1066,   261,   705,  1066,-32768,-32768,   705,
+-32768,  1066,    23,   323,-32768,     0,-32768,   705,   201,  1066,
+-32768,   274,-32768,   232,   275,-32768,   323,-32768,-32768,-32768,
+   705,   280,   705,   705,   705,   281,-32768,   705,-32768,-32768,
+   705,   705,-32768,-32768,-32768,   348,   349,-32768
 };
 
 static const short yypgoto[] = {-32768,
--32768,-32768,-32768,   126,-32768,-32768,   135,   351,   352,-32768,
-   -34,    88,    41,-32768,     1,   142,   -10,    15,   117,    96,
--32768,-32768,   178,   198,-32768,-32768,  -122,-32768,    -9,   -17,
-   -22,    28,-32768,   191,   182,   118,-32768,-32768,-32768,-32768,
-  -225,-32768,-32768,-32768,-32768,-32768,-32768,    44,-32768,    58,
--32768,-32768,-32768,-32768,-32768,   167,-32768,-32768,   183,  -223,
+-32768,-32768,-32768,   126,-32768,-32768,   135,   346,   351,-32768,
+   -34,-32768,    41,-32768,     1,   148,   -10,    15,   117,   123,
+-32768,-32768,   184,   196,-32768,-32768,  -122,-32768,    -9,   -17,
+   -22,    29,-32768,   191,   178,   118,-32768,-32768,-32768,-32768,
+  -225,-32768,-32768,-32768,-32768,-32768,-32768,    44,-32768,    55,
+-32768,-32768,-32768,-32768,-32768,   166,-32768,-32768,   182,  -223,
 -32768,     2,-32768
 };
 
@@ -530,7 +530,7 @@ static const short yytable[] = {   104,
     16,   155,   173,   142,   143,   144,   145,   146,   147,   148,
    149,   150,   151,   152,   133,   156,   157,   174,   137,   242,
    243,   244,   138,   140,   141,   237,   238,   239,   167,   168,
-    26,   310,   272,   231,   175,   274,   312,   273,    85,   153,
+    26,   310,   272,   311,   175,   274,   312,   273,    85,   153,
    180,    30,    31,   176,    86,    96,    33,   245,   246,   247,
    248,   249,   250,   276,   277,   327,   278,   194,   180,   180,
    201,   180,   280,   214,   215,   100,   100,   100,   100,   100,
@@ -538,21 +538,21 @@ static const short yytable[] = {   104,
    100,   100,   100,   100,   100,   100,   100,   100,   -27,  -126,
    224,   225,  -126,  -126,  -126,  -126,  -126,  -126,  -126,  -126,
   -126,  -126,  -126,  -126,  -126,  -126,  -126,  -126,  -126,  -126,
-  -126,  -126,  -126,   296,   -28,  -126,  -126,  -126,   273,  -126,
-  -126,   208,   316,   222,   293,   187,   301,   180,   303,   321,
-   306,   328,   341,   228,   180,   302,   180,   180,   255,   256,
-   257,   298,   169,   170,   171,   172,   223,  -126,  -126,  -126,
-   313,   233,   187,  -126,  -126,   251,   252,   253,   254,   287,
-   180,   235,  -126,  -126,   288,   180,   180,   344,   331,   240,
-   241,   262,   333,   339,   329,   180,   270,   187,   265,   275,
-   340,   279,   334,   215,   285,   289,   286,   300,   304,   307,
-   187,   308,   314,   347,   317,   349,   350,   350,   319,   320,
+  -126,  -126,  -126,   285,   -28,  -126,  -126,  -126,   286,  -126,
+  -126,   208,   296,   222,   293,   187,   301,   273,   303,   316,
+   306,   321,   328,   341,   180,   302,   180,   180,   180,   287,
+   180,   298,   169,   170,   171,   172,   223,  -126,  -126,  -126,
+   313,   228,   187,  -126,  -126,   251,   252,   253,   254,   288,
+   180,   233,  -126,  -126,   235,   255,   256,   257,   331,   180,
+   344,   262,   333,   339,   329,   240,   241,   187,   180,   265,
+   340,   270,   334,   275,   279,   215,   300,   289,   304,   307,
+   187,   314,   308,   347,   319,   349,   350,   350,   317,   320,
    354,   322,   326,   355,   355,    97,   343,     1,     2,     3,
-     4,     5,   330,   345,   348,   357,     8,   353,   358,    84,
-   284,    13,    14,   258,    16,   282,   140,   141,    87,    88,
+     4,     5,   348,   345,   330,   353,     8,   357,   358,    84,
+   284,    13,    14,    87,    16,   282,   140,   141,    88,   258,
     19,   142,   143,   144,   145,   146,   147,   148,   149,   150,
-   151,   152,   352,   311,   259,   263,    24,    25,   267,   291,
-   346,   338,   281,   269,    26,     0,     0,     0,     0,     0,
+   151,   152,   259,   352,   267,   263,    24,    25,   338,   291,
+   346,   281,   269,     0,    26,     0,     0,     0,     0,     0,
      0,     0,    85,    28,    29,    30,    31,   153,    86,     0,
     33,     0,     0,     0,     0,    34,    35,    36,    37,     0,
      0,     1,     2,     3,   118,   119,     6,     0,    98,     7,
@@ -657,19 +657,19 @@ static const short yycheck[] = {    17,
     11,    12,    13,    14,    15,    16,    17,    18,    19,    20,
     21,    22,    23,    63,    69,    26,    27,    28,    68,    30,
     31,    22,    63,    69,   264,   265,   274,    68,   276,    63,
-   278,    63,    63,    68,    68,   275,    68,    68,   173,   174,
-   175,   270,    34,    35,    36,    37,    65,    58,    59,    60,
-   290,    58,   292,    64,    65,   169,   170,   171,   172,    67,
-    68,    58,    73,    74,    67,    68,    68,    69,   316,   158,
-   159,    58,   320,   326,   314,    68,    64,   317,    84,    62,
-   328,    62,   322,    33,    63,    69,    68,    58,    64,    58,
-   330,    69,    24,   341,    84,   343,   344,   345,    65,    23,
+   278,    63,    63,    63,    68,   275,    68,    68,    68,    67,
+    68,   270,    34,    35,    36,    37,    65,    58,    59,    60,
+   290,    68,   292,    64,    65,   169,   170,   171,   172,    67,
+    68,    58,    73,    74,    58,   173,   174,   175,   316,    68,
+    69,    58,   320,   326,   314,   158,   159,   317,    68,    84,
+   328,    64,   322,    62,    62,    33,    58,    69,    64,    58,
+   330,    24,    69,   341,    65,   343,   344,   345,    84,    23,
    348,     9,    63,   351,   352,     1,    63,     3,     4,     5,
-     6,     7,    84,    69,    63,     0,    12,    65,     0,    15,
-   225,    17,    18,   176,    20,   221,    42,    43,     8,     8,
+     6,     7,    63,    69,    84,    65,    12,     0,     0,    15,
+   225,    17,    18,     8,    20,   221,    42,    43,     8,   176,
     26,    47,    48,    49,    50,    51,    52,    53,    54,    55,
-    56,    57,   345,   286,   177,   185,    42,    43,   197,   262,
-   337,   324,   216,   201,    50,    -1,    -1,    -1,    -1,    -1,
+    56,    57,   177,   345,   197,   185,    42,    43,   324,   262,
+   337,   216,   201,    -1,    50,    -1,    -1,    -1,    -1,    -1,
     -1,    -1,    58,    59,    60,    61,    62,    83,    64,    -1,
     66,    -1,    -1,    -1,    -1,    71,    72,    73,    74,    -1,
     -1,     3,     4,     5,     6,     7,     8,    -1,    84,    11,
@@ -1440,236 +1440,236 @@ case 42:
 { yyval.alist = new ArgumentListNode(yyvsp[0].node); ;
     break;}
 case 43:
-#line 249 "grammar.y"
-{ yyval.alist = new ArgumentListNode(yyvsp[0].alist, yyvsp[-2].node); ;
+#line 248 "grammar.y"
+{ yyval.alist = new ArgumentListNode(yyvsp[-2].alist, yyvsp[0].node); ;
     break;}
 case 47:
-#line 262 "grammar.y"
+#line 258 "grammar.y"
 { yyval.node = new PostfixNode(yyvsp[-1].node, OpPlusPlus); ;
     break;}
 case 48:
-#line 263 "grammar.y"
+#line 259 "grammar.y"
 { yyval.node = new PostfixNode(yyvsp[-1].node, OpMinusMinus); ;
     break;}
 case 50:
-#line 268 "grammar.y"
+#line 264 "grammar.y"
 { yyval.node = new DeleteNode(yyvsp[0].node); ;
     break;}
 case 51:
-#line 269 "grammar.y"
+#line 265 "grammar.y"
 { yyval.node = new VoidNode(yyvsp[0].node); ;
     break;}
 case 52:
-#line 270 "grammar.y"
+#line 266 "grammar.y"
 { yyval.node = new TypeOfNode(yyvsp[0].node); ;
     break;}
 case 53:
-#line 271 "grammar.y"
+#line 267 "grammar.y"
 { yyval.node = new PrefixNode(OpPlusPlus, yyvsp[0].node); ;
     break;}
 case 54:
-#line 272 "grammar.y"
+#line 268 "grammar.y"
 { yyval.node = new PrefixNode(OpPlusPlus, yyvsp[0].node); ;
     break;}
 case 55:
-#line 273 "grammar.y"
+#line 269 "grammar.y"
 { yyval.node = new PrefixNode(OpMinusMinus, yyvsp[0].node); ;
     break;}
 case 56:
-#line 274 "grammar.y"
+#line 270 "grammar.y"
 { yyval.node = new PrefixNode(OpMinusMinus, yyvsp[0].node); ;
     break;}
 case 57:
-#line 275 "grammar.y"
+#line 271 "grammar.y"
 { yyval.node = new UnaryPlusNode(yyvsp[0].node); ;
     break;}
 case 58:
-#line 276 "grammar.y"
+#line 272 "grammar.y"
 { yyval.node = new NegateNode(yyvsp[0].node); ;
     break;}
 case 59:
-#line 277 "grammar.y"
+#line 273 "grammar.y"
 { yyval.node = new BitwiseNotNode(yyvsp[0].node); ;
     break;}
 case 60:
-#line 278 "grammar.y"
+#line 274 "grammar.y"
 { yyval.node = new LogicalNotNode(yyvsp[0].node); ;
     break;}
 case 62:
-#line 283 "grammar.y"
+#line 279 "grammar.y"
 { yyval.node = new MultNode(yyvsp[-2].node, yyvsp[0].node, '*'); ;
     break;}
 case 63:
-#line 284 "grammar.y"
+#line 280 "grammar.y"
 { yyval.node = new MultNode(yyvsp[-2].node, yyvsp[0].node, '/'); ;
     break;}
 case 64:
-#line 285 "grammar.y"
+#line 281 "grammar.y"
 { yyval.node = new MultNode(yyvsp[-2].node,yyvsp[0].node,'%'); ;
     break;}
 case 66:
-#line 290 "grammar.y"
+#line 286 "grammar.y"
 { yyval.node = new AddNode(yyvsp[-2].node, yyvsp[0].node, '+'); ;
     break;}
 case 67:
-#line 291 "grammar.y"
+#line 287 "grammar.y"
 { yyval.node = new AddNode(yyvsp[-2].node, yyvsp[0].node, '-'); ;
     break;}
 case 69:
-#line 296 "grammar.y"
+#line 292 "grammar.y"
 { yyval.node = new ShiftNode(yyvsp[-2].node, OpLShift, yyvsp[0].node); ;
     break;}
 case 70:
-#line 297 "grammar.y"
+#line 293 "grammar.y"
 { yyval.node = new ShiftNode(yyvsp[-2].node, OpRShift, yyvsp[0].node); ;
     break;}
 case 71:
-#line 298 "grammar.y"
+#line 294 "grammar.y"
 { yyval.node = new ShiftNode(yyvsp[-2].node, OpURShift, yyvsp[0].node); ;
     break;}
 case 73:
-#line 304 "grammar.y"
+#line 300 "grammar.y"
 { yyval.node = new RelationalNode(yyvsp[-2].node, OpLess, yyvsp[0].node); ;
     break;}
 case 74:
-#line 306 "grammar.y"
+#line 302 "grammar.y"
 { yyval.node = new RelationalNode(yyvsp[-2].node, OpGreater, yyvsp[0].node); ;
     break;}
 case 75:
-#line 308 "grammar.y"
+#line 304 "grammar.y"
 { yyval.node = new RelationalNode(yyvsp[-2].node, OpLessEq, yyvsp[0].node); ;
     break;}
 case 76:
-#line 310 "grammar.y"
+#line 306 "grammar.y"
 { yyval.node = new RelationalNode(yyvsp[-2].node, OpGreaterEq, yyvsp[0].node); ;
     break;}
 case 77:
-#line 312 "grammar.y"
+#line 308 "grammar.y"
 { yyval.node = new RelationalNode(yyvsp[-2].node, OpInstanceOf, yyvsp[0].node); ;
     break;}
 case 78:
-#line 314 "grammar.y"
+#line 310 "grammar.y"
 { yyval.node = new RelationalNode(yyvsp[-2].node, OpIn, yyvsp[0].node); ;
     break;}
 case 80:
-#line 319 "grammar.y"
+#line 315 "grammar.y"
 { yyval.node = new EqualNode(yyvsp[-2].node, OpEqEq, yyvsp[0].node); ;
     break;}
 case 81:
-#line 320 "grammar.y"
+#line 316 "grammar.y"
 { yyval.node = new EqualNode(yyvsp[-2].node, OpNotEq, yyvsp[0].node); ;
     break;}
 case 82:
-#line 321 "grammar.y"
+#line 317 "grammar.y"
 { yyval.node = new EqualNode(yyvsp[-2].node, OpStrEq, yyvsp[0].node); ;
     break;}
 case 83:
-#line 322 "grammar.y"
+#line 318 "grammar.y"
 { yyval.node = new EqualNode(yyvsp[-2].node, OpStrNEq, yyvsp[0].node);;
     break;}
 case 85:
-#line 327 "grammar.y"
+#line 323 "grammar.y"
 { yyval.node = new BitOperNode(yyvsp[-2].node, OpBitAnd, yyvsp[0].node); ;
     break;}
 case 87:
-#line 332 "grammar.y"
+#line 328 "grammar.y"
 { yyval.node = new BitOperNode(yyvsp[-2].node, OpBitXOr, yyvsp[0].node); ;
     break;}
 case 89:
-#line 337 "grammar.y"
+#line 333 "grammar.y"
 { yyval.node = new BitOperNode(yyvsp[-2].node, OpBitOr, yyvsp[0].node); ;
     break;}
 case 91:
-#line 343 "grammar.y"
+#line 339 "grammar.y"
 { yyval.node = new BinaryLogicalNode(yyvsp[-2].node, OpAnd, yyvsp[0].node); ;
     break;}
 case 93:
-#line 349 "grammar.y"
+#line 345 "grammar.y"
 { yyval.node = new BinaryLogicalNode(yyvsp[-2].node, OpOr, yyvsp[0].node); ;
     break;}
 case 95:
-#line 355 "grammar.y"
+#line 351 "grammar.y"
 { yyval.node = new ConditionalNode(yyvsp[-4].node, yyvsp[-2].node, yyvsp[0].node); ;
     break;}
 case 97:
-#line 361 "grammar.y"
+#line 357 "grammar.y"
 { yyval.node = new AssignNode(yyvsp[-2].node, yyvsp[-1].op, yyvsp[0].node);;
     break;}
 case 98:
-#line 365 "grammar.y"
+#line 361 "grammar.y"
 { yyval.op = OpEqual; ;
     break;}
 case 99:
-#line 366 "grammar.y"
+#line 362 "grammar.y"
 { yyval.op = OpPlusEq; ;
     break;}
 case 100:
-#line 367 "grammar.y"
+#line 363 "grammar.y"
 { yyval.op = OpMinusEq; ;
     break;}
 case 101:
-#line 368 "grammar.y"
+#line 364 "grammar.y"
 { yyval.op = OpMultEq; ;
     break;}
 case 102:
-#line 369 "grammar.y"
+#line 365 "grammar.y"
 { yyval.op = OpDivEq; ;
     break;}
 case 103:
-#line 370 "grammar.y"
+#line 366 "grammar.y"
 { yyval.op = OpLShift; ;
     break;}
 case 104:
-#line 371 "grammar.y"
+#line 367 "grammar.y"
 { yyval.op = OpRShift; ;
     break;}
 case 105:
-#line 372 "grammar.y"
+#line 368 "grammar.y"
 { yyval.op = OpURShift; ;
     break;}
 case 106:
-#line 373 "grammar.y"
+#line 369 "grammar.y"
 { yyval.op = OpAndEq; ;
     break;}
 case 107:
-#line 374 "grammar.y"
+#line 370 "grammar.y"
 { yyval.op = OpXOrEq; ;
     break;}
 case 108:
-#line 375 "grammar.y"
+#line 371 "grammar.y"
 { yyval.op = OpOrEq; ;
     break;}
 case 109:
-#line 376 "grammar.y"
+#line 372 "grammar.y"
 { yyval.op = OpModEq; ;
     break;}
 case 111:
-#line 381 "grammar.y"
+#line 377 "grammar.y"
 { yyval.node = new CommaNode(yyvsp[-2].node, yyvsp[0].node); ;
     break;}
 case 126:
-#line 402 "grammar.y"
+#line 398 "grammar.y"
 { yyval.stat = new BlockNode(0L); DBG(yyval.stat, yylsp[0], yylsp[0]); ;
     break;}
 case 127:
-#line 403 "grammar.y"
+#line 399 "grammar.y"
 { yyval.stat = new BlockNode(yyvsp[-1].srcs); DBG(yyval.stat, yylsp[0], yylsp[0]); ;
     break;}
 case 128:
-#line 407 "grammar.y"
+#line 403 "grammar.y"
 { yyval.slist = new StatListNode(yyvsp[0].stat); ;
     break;}
 case 129:
-#line 408 "grammar.y"
+#line 404 "grammar.y"
 { yyval.slist = new StatListNode(yyvsp[-1].slist, yyvsp[0].stat); ;
     break;}
 case 130:
-#line 412 "grammar.y"
+#line 408 "grammar.y"
 { yyval.stat = new VarStatementNode(yyvsp[-1].vlist);
                                       DBG(yyval.stat, yylsp[-2], yylsp[0]); ;
     break;}
 case 131:
-#line 414 "grammar.y"
+#line 410 "grammar.y"
 { if (automatic()) {
                                           yyval.stat = new VarStatementNode(yyvsp[-1].vlist);
 					  DBG(yyval.stat, yylsp[-2], yylsp[-1]);
@@ -1679,36 +1679,36 @@ case 131:
                                       ;
     break;}
 case 132:
-#line 424 "grammar.y"
+#line 420 "grammar.y"
 { yyval.vlist = new VarDeclListNode(yyvsp[0].decl); ;
     break;}
 case 133:
-#line 426 "grammar.y"
+#line 422 "grammar.y"
 { yyval.vlist = new VarDeclListNode(yyvsp[-2].vlist, yyvsp[0].decl); ;
     break;}
 case 134:
-#line 430 "grammar.y"
+#line 426 "grammar.y"
 { yyval.decl = new VarDeclNode(*yyvsp[0].ident, 0); delete yyvsp[0].ident; ;
     break;}
 case 135:
-#line 431 "grammar.y"
+#line 427 "grammar.y"
 { yyval.decl = new VarDeclNode(*yyvsp[-1].ident, yyvsp[0].init); delete yyvsp[-1].ident; ;
     break;}
 case 136:
-#line 435 "grammar.y"
+#line 431 "grammar.y"
 { yyval.init = new AssignExprNode(yyvsp[0].node); ;
     break;}
 case 137:
-#line 439 "grammar.y"
+#line 435 "grammar.y"
 { yyval.stat = new EmptyStatementNode(); ;
     break;}
 case 138:
-#line 443 "grammar.y"
+#line 439 "grammar.y"
 { yyval.stat = new ExprStatementNode(yyvsp[-1].node);
                                      DBG(yyval.stat, yylsp[-1], yylsp[0]); ;
     break;}
 case 139:
-#line 445 "grammar.y"
+#line 441 "grammar.y"
 { if (automatic()) {
                                        yyval.stat = new ExprStatementNode(yyvsp[-1].node);
 				       DBG(yyval.stat, yylsp[-1], yylsp[-1]);
@@ -1716,70 +1716,70 @@ case 139:
 				       YYABORT; ;
     break;}
 case 140:
-#line 453 "grammar.y"
+#line 449 "grammar.y"
 { yyval.stat = new IfNode(yyvsp[-2].node,yyvsp[0].stat,0L);DBG(yyval.stat,yylsp[-4],yylsp[-1]); ;
     break;}
 case 141:
-#line 455 "grammar.y"
+#line 451 "grammar.y"
 { yyval.stat = new IfNode(yyvsp[-4].node,yyvsp[-2].stat,yyvsp[0].stat);DBG(yyval.stat,yylsp[-6],yylsp[-3]); ;
     break;}
 case 142:
-#line 459 "grammar.y"
+#line 455 "grammar.y"
 { yyval.stat=new DoWhileNode(yyvsp[-4].stat,yyvsp[-1].node);DBG(yyval.stat,yylsp[-5],yylsp[-3]);;
     break;}
 case 143:
-#line 460 "grammar.y"
+#line 456 "grammar.y"
 { yyval.stat = new WhileNode(yyvsp[-2].node,yyvsp[0].stat);DBG(yyval.stat,yylsp[-4],yylsp[-1]); ;
     break;}
 case 144:
-#line 462 "grammar.y"
+#line 458 "grammar.y"
 { yyval.stat = new ForNode(yyvsp[-6].node,yyvsp[-4].node,yyvsp[-2].node,yyvsp[0].stat);
 	                             DBG(yyval.stat,yylsp[-8],yylsp[-1]); ;
     break;}
 case 145:
-#line 465 "grammar.y"
+#line 461 "grammar.y"
 { yyval.stat = new ForNode(yyvsp[-6].vlist,yyvsp[-4].node,yyvsp[-2].node,yyvsp[0].stat);
 	                             DBG(yyval.stat,yylsp[-9],yylsp[-1]); ;
     break;}
 case 146:
-#line 468 "grammar.y"
+#line 464 "grammar.y"
 { yyval.stat = new ForInNode(yyvsp[-4].node, yyvsp[-2].node, yyvsp[0].stat);
 	                             DBG(yyval.stat,yylsp[-6],yylsp[-1]); ;
     break;}
 case 147:
-#line 471 "grammar.y"
+#line 467 "grammar.y"
 { yyval.stat = new ForInNode(*yyvsp[-4].ident,0L,yyvsp[-2].node,yyvsp[0].stat);
 	                             DBG(yyval.stat,yylsp[-7],yylsp[-1]);
                                      delete yyvsp[-4].ident; ;
     break;}
 case 148:
-#line 475 "grammar.y"
+#line 471 "grammar.y"
 { yyval.stat = new ForInNode(*yyvsp[-5].ident,yyvsp[-4].init,yyvsp[-2].node,yyvsp[0].stat);
 	                             DBG(yyval.stat,yylsp[-8],yylsp[-1]);
                                      delete yyvsp[-5].ident; ;
     break;}
 case 149:
-#line 481 "grammar.y"
+#line 477 "grammar.y"
 { yyval.node = 0L; ;
     break;}
 case 151:
-#line 486 "grammar.y"
+#line 482 "grammar.y"
 { yyval.stat = new ContinueNode(); DBG(yyval.stat,yylsp[-1],yylsp[0]); ;
     break;}
 case 152:
-#line 487 "grammar.y"
+#line 483 "grammar.y"
 { if (automatic()) {
                                        yyval.stat = new ContinueNode(); DBG(yyval.stat,yylsp[-1],yylsp[0]);
                                      } else
 				       YYABORT; ;
     break;}
 case 153:
-#line 491 "grammar.y"
+#line 487 "grammar.y"
 { yyval.stat = new ContinueNode(*yyvsp[-1].ident); DBG(yyval.stat,yylsp[-2],yylsp[0]);
                                      delete yyvsp[-1].ident; ;
     break;}
 case 154:
-#line 493 "grammar.y"
+#line 489 "grammar.y"
 { if (automatic()) {
                                        yyval.stat = new ContinueNode(*yyvsp[-1].ident);DBG(yyval.stat,yylsp[-2],yylsp[-1]);
 				       delete yyvsp[-1].ident;
@@ -1787,23 +1787,23 @@ case 154:
 				       YYABORT; ;
     break;}
 case 155:
-#line 501 "grammar.y"
+#line 497 "grammar.y"
 { yyval.stat = new BreakNode();DBG(yyval.stat,yylsp[-1],yylsp[0]); ;
     break;}
 case 156:
-#line 502 "grammar.y"
+#line 498 "grammar.y"
 { if (automatic()) {
                                        yyval.stat = new BreakNode(); DBG(yyval.stat,yylsp[-1],yylsp[-1]);
                                      } else
 				       YYABORT; ;
     break;}
 case 157:
-#line 506 "grammar.y"
+#line 502 "grammar.y"
 { yyval.stat = new BreakNode(*yyvsp[-1].ident); DBG(yyval.stat,yylsp[-2],yylsp[0]);
                                      delete yyvsp[-1].ident; ;
     break;}
 case 158:
-#line 508 "grammar.y"
+#line 504 "grammar.y"
 { if (automatic()) {
                                        yyval.stat = new BreakNode(*yyvsp[-1].ident); DBG(yyval.stat,yylsp[-2],yylsp[-1]);
 				       delete yyvsp[-1].ident;
@@ -1812,164 +1812,164 @@ case 158:
                                    ;
     break;}
 case 159:
-#line 517 "grammar.y"
+#line 513 "grammar.y"
 { yyval.stat = new ReturnNode(0L); DBG(yyval.stat,yylsp[-1],yylsp[0]); ;
     break;}
 case 160:
-#line 518 "grammar.y"
+#line 514 "grammar.y"
 { if (automatic()) {
                                        yyval.stat = new ReturnNode(0L); DBG(yyval.stat,yylsp[-1],yylsp[-1]);
                                      } else
 				       YYABORT; ;
     break;}
 case 161:
-#line 522 "grammar.y"
+#line 518 "grammar.y"
 { yyval.stat = new ReturnNode(yyvsp[-1].node); ;
     break;}
 case 162:
-#line 523 "grammar.y"
+#line 519 "grammar.y"
 { if (automatic())
                                        yyval.stat = new ReturnNode(yyvsp[-1].node);
                                      else
 				       YYABORT; ;
     break;}
 case 163:
-#line 530 "grammar.y"
+#line 526 "grammar.y"
 { yyval.stat = new WithNode(yyvsp[-2].node,yyvsp[0].stat);
                                      DBG(yyval.stat, yylsp[-4], yylsp[-1]); ;
     break;}
 case 164:
-#line 535 "grammar.y"
+#line 531 "grammar.y"
 { yyval.stat = new SwitchNode(yyvsp[-2].node, yyvsp[0].cblk);
                                      DBG(yyval.stat, yylsp[-4], yylsp[-1]); ;
     break;}
 case 165:
-#line 540 "grammar.y"
+#line 536 "grammar.y"
 { yyval.cblk = new CaseBlockNode(yyvsp[-1].clist, 0L, 0L); ;
     break;}
 case 166:
-#line 542 "grammar.y"
+#line 538 "grammar.y"
 { yyval.cblk = new CaseBlockNode(yyvsp[-3].clist, yyvsp[-2].ccl, yyvsp[-1].clist); ;
     break;}
 case 167:
-#line 546 "grammar.y"
+#line 542 "grammar.y"
 { yyval.clist = 0L; ;
     break;}
 case 169:
-#line 551 "grammar.y"
+#line 547 "grammar.y"
 { yyval.clist = new ClauseListNode(yyvsp[0].ccl); ;
     break;}
 case 170:
-#line 552 "grammar.y"
+#line 548 "grammar.y"
 { yyval.clist = yyvsp[-1].clist->append(yyvsp[0].ccl); ;
     break;}
 case 171:
-#line 556 "grammar.y"
+#line 552 "grammar.y"
 { yyval.ccl = new CaseClauseNode(yyvsp[-1].node, 0L); ;
     break;}
 case 172:
-#line 557 "grammar.y"
+#line 553 "grammar.y"
 { yyval.ccl = new CaseClauseNode(yyvsp[-2].node, yyvsp[0].slist); ;
     break;}
 case 173:
-#line 561 "grammar.y"
+#line 557 "grammar.y"
 { yyval.ccl = new CaseClauseNode(0L, 0L);; ;
     break;}
 case 174:
-#line 562 "grammar.y"
+#line 558 "grammar.y"
 { yyval.ccl = new CaseClauseNode(0L, yyvsp[0].slist); ;
     break;}
 case 175:
-#line 566 "grammar.y"
+#line 562 "grammar.y"
 { yyvsp[0].stat->pushLabel(*yyvsp[-2].ident);
                                      yyval.stat = new LabelNode(*yyvsp[-2].ident, yyvsp[0].stat);
                                      delete yyvsp[-2].ident; ;
     break;}
 case 176:
-#line 572 "grammar.y"
+#line 568 "grammar.y"
 { yyval.stat = new ThrowNode(yyvsp[-1].node); ;
     break;}
 case 177:
-#line 576 "grammar.y"
+#line 572 "grammar.y"
 { yyval.stat = new TryNode(yyvsp[-1].stat, yyvsp[0].node); ;
     break;}
 case 178:
-#line 577 "grammar.y"
+#line 573 "grammar.y"
 { yyval.stat = new TryNode(yyvsp[-1].stat, 0L, yyvsp[0].node); ;
     break;}
 case 179:
-#line 578 "grammar.y"
+#line 574 "grammar.y"
 { yyval.stat = new TryNode(yyvsp[-2].stat, yyvsp[-1].node, yyvsp[0].node); ;
     break;}
 case 180:
-#line 582 "grammar.y"
+#line 578 "grammar.y"
 { yyval.node = new CatchNode(*yyvsp[-2].ident, yyvsp[0].stat); delete yyvsp[-2].ident; ;
     break;}
 case 181:
-#line 586 "grammar.y"
+#line 582 "grammar.y"
 { yyval.node = new FinallyNode(yyvsp[0].stat); ;
     break;}
 case 182:
-#line 590 "grammar.y"
+#line 586 "grammar.y"
 { yyval.func = new FuncDeclNode(*yyvsp[-3].ident, 0L, yyvsp[0].body);
                                              delete yyvsp[-3].ident; ;
     break;}
 case 183:
-#line 593 "grammar.y"
+#line 589 "grammar.y"
 { yyval.func = new FuncDeclNode(*yyvsp[-4].ident, yyvsp[-2].param, yyvsp[0].body);
                                      delete yyvsp[-4].ident; ;
     break;}
 case 184:
-#line 597 "grammar.y"
+#line 593 "grammar.y"
 { yyval.node = new FuncExprNode(0L, yyvsp[0].body); ;
     break;}
 case 185:
-#line 599 "grammar.y"
+#line 595 "grammar.y"
 { yyval.node = new FuncExprNode(yyvsp[-2].param, yyvsp[0].body); ;
     break;}
 case 186:
-#line 604 "grammar.y"
+#line 600 "grammar.y"
 { yyval.param = new ParameterNode(*yyvsp[0].ident); delete yyvsp[0].ident; ;
     break;}
 case 187:
-#line 605 "grammar.y"
+#line 601 "grammar.y"
 { yyval.param = yyvsp[-2].param->append(*yyvsp[0].ident);
 	                             delete yyvsp[0].ident; ;
     break;}
 case 188:
-#line 610 "grammar.y"
+#line 606 "grammar.y"
 { yyval.body = new FunctionBodyNode(0L);
 	                             DBG(yyval.body, yylsp[-1], yylsp[0]);;
     break;}
 case 189:
-#line 612 "grammar.y"
+#line 608 "grammar.y"
 { yyval.body = new FunctionBodyNode(yyvsp[-1].srcs);
 	                             DBG(yyval.body, yylsp[-2], yylsp[0]);;
     break;}
 case 190:
-#line 617 "grammar.y"
+#line 613 "grammar.y"
 { yyval.prog = new ProgramNode(0L);
                                      Parser::progNode = yyval.prog; ;
     break;}
 case 191:
-#line 619 "grammar.y"
+#line 615 "grammar.y"
 { yyval.prog = new ProgramNode(yyvsp[0].srcs);
                                      Parser::progNode = yyval.prog; ;
     break;}
 case 192:
-#line 624 "grammar.y"
+#line 620 "grammar.y"
 { yyval.srcs = new SourceElementsNode(yyvsp[0].src); ;
     break;}
 case 193:
-#line 626 "grammar.y"
+#line 622 "grammar.y"
 { yyval.srcs = new SourceElementsNode(yyvsp[0].srcs, yyvsp[-1].src); ;
     break;}
 case 194:
-#line 633 "grammar.y"
+#line 629 "grammar.y"
 { yyval.src = new SourceElementNode(yyvsp[0].stat); ;
     break;}
 case 195:
-#line 634 "grammar.y"
+#line 630 "grammar.y"
 { yyval.src = new SourceElementNode(yyvsp[0].func); ;
     break;}
 }
@@ -2194,7 +2194,7 @@ yyerrhandle:
     }
   return 1;
 }
-#line 637 "grammar.y"
+#line 633 "grammar.y"
 
 
 int yyerror (const char *)  /* Called by yyparse on error */
diff --git a/JavaScriptCore/kjs/grammar.y b/JavaScriptCore/kjs/grammar.y
index 9aef96e..5ad326f 100644
--- a/JavaScriptCore/kjs/grammar.y
+++ b/JavaScriptCore/kjs/grammar.y
@@ -245,11 +245,7 @@ Arguments:
 
 ArgumentList:
     AssignmentExpr                  { $$ = new ArgumentListNode($1); }
-/* #ifdef APPLE_CHANGES (not using an actual ifdef because this is yacc) */
-   | AssignmentExpr ',' ArgumentList { $$ = new ArgumentListNode($3, $1); }
-/* #else */
-/* | ArgumentList ',' AssignmentExpr { $$ = new ArgumentListNode($1, $3); } */
-/* #endif */
+  | ArgumentList ',' AssignmentExpr { $$ = new ArgumentListNode($1, $3); }
 ;
 
 LeftHandSideExpr:
diff --git a/JavaScriptCore/kjs/nodes.cpp b/JavaScriptCore/kjs/nodes.cpp
index 4d5d453..30d4b3b 100644
--- a/JavaScriptCore/kjs/nodes.cpp
+++ b/JavaScriptCore/kjs/nodes.cpp
@@ -615,6 +615,19 @@ List ArgumentListNode::evaluateList(ExecState *exec)
 
 ArgumentsNode::ArgumentsNode(ArgumentListNode *l) : list(l)
 {
+  if (list == NULL) {
+    return;
+  }
+
+  ArgumentListNode *prev = list;
+  ArgumentListNode *cur = prev->list;
+  
+  while (cur != NULL) {
+    prev->list = cur->list;
+    cur->list = list;
+    list = cur;
+    cur = prev->list;
+  }
 }
 
 void ArgumentsNode::ref()
diff --git a/JavaScriptCore/kjs/nodes.h b/JavaScriptCore/kjs/nodes.h
index 171b08b..c334c92 100644
--- a/JavaScriptCore/kjs/nodes.h
+++ b/JavaScriptCore/kjs/nodes.h
@@ -314,6 +314,7 @@ namespace KJS {
     List evaluateList(ExecState *exec);
     virtual void streamTo(SourceStream &s) const;
   private:
+    friend class ArgumentsNode;
     ArgumentListNode *list;
     Node *expr;
   };

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list