summaryrefslogtreecommitdiffstats
path: root/js/src/tests/test262/ch12/12.6/12.6.3
diff options
context:
space:
mode:
authorMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
committerMatt A. Tobin <mattatobin@localhost.localdomain>2018-02-02 04:16:08 -0500
commit5f8de423f190bbb79a62f804151bc24824fa32d8 (patch)
tree10027f336435511475e392454359edea8e25895d /js/src/tests/test262/ch12/12.6/12.6.3
parent49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff)
downloadUXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz
UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip
Add m-esr52 at 52.6.0
Diffstat (limited to 'js/src/tests/test262/ch12/12.6/12.6.3')
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-1.js26
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-10.js26
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-11.js24
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-12.js24
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-13.js24
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-14.js24
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-15.js24
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-16.js24
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-17.js25
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-18.js24
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-19.js25
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-2.js26
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-20.js25
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-21.js25
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-3.js26
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-4.js26
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-5.js26
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-6.js26
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-7.js26
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-8.js26
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-9.js26
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A1.js36
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A10.1.js111
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A10.js51
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T1.js21
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T2.js63
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T3.js27
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T1.js21
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T2.js63
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T3.js27
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T1.js21
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T2.js64
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T3.js24
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T1.js21
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T2.js64
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T3.js27
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A13.js25
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A14.js46
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A15.js24
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.1.js25
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.2.js25
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.js33
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A3.js41
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4.1.js22
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4_T1.js22
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4_T2.js22
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A5.js42
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A6.js33
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7.1_T1.js18
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7.1_T2.js18
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7_T1.js18
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7_T2.js18
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T1.js19
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T2.js22
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T3.js22
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T1.js19
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T2.js19
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T3.js22
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A9.1.js25
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A9.js25
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/browser.js0
-rw-r--r--js/src/tests/test262/ch12/12.6/12.6.3/shell.js0
62 files changed, 1774 insertions, 0 deletions
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-1.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-1.js
new file mode 100644
index 000000000..a0aa03156
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-1.js
@@ -0,0 +1,26 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-1.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is an Object with value false
+ */
+
+
+function testcase() {
+ var accessed = false;
+ var obj = { value: false };
+ for (var i = 0; obj; ) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-10.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-10.js
new file mode 100644
index 000000000..cc1cb63d6
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-10.js
@@ -0,0 +1,26 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-10.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a String object (value is '1')
+ */
+
+
+function testcase() {
+ var accessed = false;
+ var strObj = new String("1");
+ for (var i = 0; strObj;) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-11.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-11.js
new file mode 100644
index 000000000..2bccf56df
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-11.js
@@ -0,0 +1,24 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-11.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is undefined
+ */
+
+
+function testcase() {
+ var count = 0;
+ for (var i = 0; undefined;) {
+ count++;
+ }
+ return count === 0;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-12.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-12.js
new file mode 100644
index 000000000..6698b966b
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-12.js
@@ -0,0 +1,24 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-12.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is null
+ */
+
+
+function testcase() {
+ var count = 0;
+ for (var i = 0; null;) {
+ count++;
+ }
+ return count === 0;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-13.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-13.js
new file mode 100644
index 000000000..4e7d39333
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-13.js
@@ -0,0 +1,24 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-13.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a boolean (value is false)
+ */
+
+
+function testcase() {
+ var count = 0;
+ for (var i = 0; false;) {
+ count++;
+ }
+ return count === 0;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-14.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-14.js
new file mode 100644
index 000000000..865f68d77
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-14.js
@@ -0,0 +1,24 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-14.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a number (value is NaN)
+ */
+
+
+function testcase() {
+ var count = 0;
+ for (var i = 0; NaN;) {
+ count++;
+ }
+ return count === 0;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-15.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-15.js
new file mode 100644
index 000000000..8f85811f3
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-15.js
@@ -0,0 +1,24 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-15.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a number (value is +0)
+ */
+
+
+function testcase() {
+ var count = 0;
+ for (var i = 0; +0;) {
+ count++;
+ }
+ return count === 0;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-16.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-16.js
new file mode 100644
index 000000000..20d03326e
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-16.js
@@ -0,0 +1,24 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-16.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a number (value is -0)
+ */
+
+
+function testcase() {
+ var count = 0;
+ for (var i = 0; -0;) {
+ count++;
+ }
+ return count === 0;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-17.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-17.js
new file mode 100644
index 000000000..faca41566
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-17.js
@@ -0,0 +1,25 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-17.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a number (value is a positive)
+ */
+
+
+function testcase() {
+ var accessed = false;
+ for (var i = 0; 2;) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-18.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-18.js
new file mode 100644
index 000000000..8fc6251de
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-18.js
@@ -0,0 +1,24 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-18.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a string (value is empty string)
+ */
+
+
+function testcase() {
+ var count = 0;
+ for (var i = 0; "";) {
+ count++;
+ }
+ return count === 0;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-19.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-19.js
new file mode 100644
index 000000000..19dc79e05
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-19.js
@@ -0,0 +1,25 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-19.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a string (value is 'undefined')
+ */
+
+
+function testcase() {
+ var accessed = false;
+ for (var i = 0; "undefined";) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-2.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-2.js
new file mode 100644
index 000000000..eaf600c6e
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-2.js
@@ -0,0 +1,26 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-2.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a Boolean object
+ */
+
+
+function testcase() {
+ var accessed = false;
+ var boolObj = new Boolean(false);
+ for (var i = 0; boolObj;) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-20.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-20.js
new file mode 100644
index 000000000..6c8e61c59
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-20.js
@@ -0,0 +1,25 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-20.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a string (value is 'null')
+ */
+
+
+function testcase() {
+ var accessed = false;
+ for (var i = 0; "null";) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-21.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-21.js
new file mode 100644
index 000000000..d83bd0b18
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-21.js
@@ -0,0 +1,25 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-21.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a string (value is '1')
+ */
+
+
+function testcase() {
+ var accessed = false;
+ for (var i = 0; "1";) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-3.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-3.js
new file mode 100644
index 000000000..76f27f8bd
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-3.js
@@ -0,0 +1,26 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-3.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a Number object (value is NaN)
+ */
+
+
+function testcase() {
+ var accessed = false;
+ var numObj = new Number(NaN);
+ for (var i = 0; numObj;) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-4.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-4.js
new file mode 100644
index 000000000..81599d37b
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-4.js
@@ -0,0 +1,26 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-4.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a Number object (value is +0)
+ */
+
+
+function testcase() {
+ var accessed = false;
+ var numObj = new Number(+0);
+ for (var i = 0; numObj;) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-5.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-5.js
new file mode 100644
index 000000000..5a3199947
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-5.js
@@ -0,0 +1,26 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-5.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a Number object (value is -0)
+ */
+
+
+function testcase() {
+ var accessed = false;
+ var numObj = new Number(-0);
+ for (var i = 0; numObj;) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-6.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-6.js
new file mode 100644
index 000000000..6f8ed9cd3
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-6.js
@@ -0,0 +1,26 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-6.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a Number object (value is a positive)
+ */
+
+
+function testcase() {
+ var accessed = false;
+ var numObj = new Number(12);
+ for (var i = 0; numObj;) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-7.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-7.js
new file mode 100644
index 000000000..920911c94
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-7.js
@@ -0,0 +1,26 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-7.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a String object (value is empty string)
+ */
+
+
+function testcase() {
+ var accessed = false;
+ var strObj = new String("");
+ for (var i = 0; strObj;) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-8.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-8.js
new file mode 100644
index 000000000..f087aa207
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-8.js
@@ -0,0 +1,26 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-8.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a String object (value is 'undefined')
+ */
+
+
+function testcase() {
+ var accessed = false;
+ var strObj = new String("undefined");
+ for (var i = 0; strObj;) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-9.js b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-9.js
new file mode 100644
index 000000000..45ed58923
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/12.6.3_2-3-a-ii-9.js
@@ -0,0 +1,26 @@
+/// Copyright (c) 2012 Ecma International. All rights reserved.
+/// Ecma International makes this code available under the terms and conditions set
+/// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
+/// "Use Terms"). Any redistribution of this code must retain the above
+/// copyright and this notice and otherwise comply with the Use Terms.
+/**
+ * Refer 12.6.3;
+ * The production
+ * IterationStatement : for ( var VariableDeclarationListNoIn ; Expressionopt ; Expressionopt ) Statement
+ * is evaluated as follows:
+ *
+ * @path ch12/12.6/12.6.3/12.6.3_2-3-a-ii-9.js
+ * @description The for Statement - (normal, V, empty) will be returned when first Expression is a String object (value is 'null')
+ */
+
+
+function testcase() {
+ var accessed = false;
+ var strObj = new String("null");
+ for (var i = 0; strObj;) {
+ accessed = true;
+ break;
+ }
+ return accessed;
+ }
+runTestCase(testcase);
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A1.js
new file mode 100644
index 000000000..dd200559c
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A1.js
@@ -0,0 +1,36 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * The "for {;;}" for Statement with empty expressions is allowed and leads to performing an infinite loop
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A1.js
+ * @description Breaking an infinite loop by throwing exception
+ */
+
+var __in__for = 0;
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+try {
+ for (;;){
+ //__in__for++;
+ if(++__in__for>100)throw 1;
+}
+} catch (e) {
+ if (e !== 1) {
+ $ERROR('#1: for {;;} is admitted and leads to infinite loop');
+ }
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+if (__in__for !== 101) {
+ $ERROR('#2: __in__for === 101. Actual: __in__for ==='+ __in__for );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A10.1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A10.1.js
new file mode 100644
index 000000000..13bfc59ff
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A10.1.js
@@ -0,0 +1,111 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Nested "var-loops" nine blocks depth is evaluated properly
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A10.1.js
+ * @description Checking if executing nested "var-loops" nine blocks depth is evaluated properly
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+try {
+ __in__deepest__loop=__in__deepest__loop;
+} catch (e) {
+ $ERROR('#1: "__in__deepest__loop=__in__deepest__loop" does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+try {
+ index0=index0;
+} catch (e) {
+ $ERROR('#2: "index0=index0" does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#3
+try {
+ index1=index1;
+} catch (e) {
+ $ERROR('#3: "index1=index1" does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#4
+try {
+ index4=index4;
+} catch (e) {
+ $ERROR('#4: "index4=index4" does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#5
+try {
+ index5=index5;
+} catch (e) {
+ $ERROR('#4: "index5=index5" does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#6
+try {
+ index7=index7;
+} catch (e) {
+ $ERROR('#6: "index7=index7" does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#7
+try {
+ index8=index8;
+} catch (e) {
+ $ERROR('#7: "index8=index8" does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+__str="";
+
+for( var index0=0; index0<=1; index0++) {
+ for(var index1=0; index1<=index0; index1++) {
+ for( index2=0; index2<=index1; index2++) {
+ for( index3=0; index3<=index2; index3++) {
+ for(var index4=0; index4<=index3; index4++) {
+ for(var index5=0; index5<=index4; index5++) {
+ for( index6=0; index6<=index5; index6++) {
+ for(var index7=0; index7<=index6; index7++) {
+ for(var index8=0; index8<=index1; index8++) {
+ var __in__deepest__loop;
+ __str+=""+index0+index1+index2+index3+index4+index5+index6+index7+index8+'\n';
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+if (__str!== "000000000\n100000000\n110000000\n110000001\n111000000\n111000001\n111100000\n111100001\n111110000\n111110001\n111111000\n111111001\n111111100\n111111101\n111111110\n111111111\n") {
+ $ERROR('#2: __str === "000000000\\n100000000\\n110000000\\n110000001\\n111000000\\n111000001\\n111100000\\n111100001\\n111110000\\n111110001\\n111111000\\n111111001\\n111111100\\n111111101\\n111111110\\n111111111\\n". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A10.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A10.js
new file mode 100644
index 000000000..fb17b0b2c
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A10.js
@@ -0,0 +1,51 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Nested "var-loops" nine blocks depth is evaluated properly
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A10.js
+ * @description Checking if executing nested "var-loops" nine blocks depth is evaluated properly
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#
+try {
+ __in__deepest__loop=__in__deepest__loop;
+} catch (e) {
+ $ERROR('#1: "__in__deepest__loop=__in__deepest__loop" does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+__str="";
+
+for( index0=0; index0<=1; index0++) {
+ for( index1=0; index1<=index0; index1++) {
+ for( index2=0; index2<=index1; index2++) {
+ for( index3=0; index3<=index2; index3++) {
+ for( index4=0; index4<=index3; index4++) {
+ for( index5=0; index5<=index4; index5++) {
+ for( index6=0; index6<=index5; index6++) {
+ for( index7=0; index7<=index6; index7++) {
+ for( index8=0; index8<=index1; index8++) {
+ var __in__deepest__loop;
+ __str+=""+index0+index1+index2+index3+index4+index5+index6+index7+index8+'\n';
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+if (__str!== "000000000\n100000000\n110000000\n110000001\n111000000\n111000001\n111100000\n111100001\n111110000\n111110001\n111111000\n111111001\n111111100\n111111101\n111111110\n111111111\n") {
+ $ERROR('#2: __str === "000000000\\n100000000\\n110000000\\n110000001\\n111000000\\n111000001\\n111100000\\n111100001\\n111110000\\n111110001\\n111111000\\n111111001\\n111111100\\n111111101\\n111111110\\n111111111\\n". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T1.js
new file mode 100644
index 000000000..d050b3dbc
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T1.js
@@ -0,0 +1,21 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "continue" and (Evaluate Statement).target is in the current label set, iteration of labeled "var-loop" breaks
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A11.1_T1.js
+ * @description Using "continue" in order to continue a loop
+ */
+
+__str=""
+
+for(var index=0; index<10; index+=1) {
+ if (index<5)continue;
+ __str+=index;
+}
+
+if (__str!=="56789") {
+ $ERROR('#1: __str === "56789". Actual: __str ==='+ __str );
+}
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T2.js
new file mode 100644
index 000000000..cc0233d41
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T2.js
@@ -0,0 +1,63 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "continue" and (Evaluate Statement).target is in the current label set, iteration of labeled "var-loop" breaks
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A11.1_T2.js
+ * @description Embedded loops
+ */
+
+__str="";
+
+outer : for(var index=0; index<4; index+=1) {
+ nested : for(var index_n=0; index_n<=index; index_n++) {
+ if (index*index_n == 6)continue nested;
+ __str+=""+index+index_n;
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+if (__str !== "001011202122303133") {
+ $ERROR('#1: __str === "001011202122303133". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+__str="";
+
+outer : for(var index=0; index<4; index+=1) {
+ nested : for(var index_n=0; index_n<=index; index_n++) {
+ if (index*index_n == 6)continue outer;
+ __str+=""+index+index_n;
+ }
+}
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+if (__str !== "0010112021223031") {
+ $ERROR('#2: __str === "0010112021223031". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+__str="";
+
+outer : for(var index=0; index<4; index+=1) {
+ nested : for(var index_n=0; index_n<=index; index_n++) {
+ if (index*index_n == 6)continue ;
+ __str+=""+index+index_n;
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#3
+if (__str !== "001011202122303133") {
+ $ERROR('#3: __str === "001011202122303133". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T3.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T3.js
new file mode 100644
index 000000000..d02abf292
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11.1_T3.js
@@ -0,0 +1,27 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "continue" and (Evaluate Statement).target is in the current label set, iteration of labeled "var-loop" breaks
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A11.1_T3.js
+ * @description Trying to continue non-existent label
+ * @negative
+ */
+
+__str="";
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+outer:for(var index=0;index<4;index+=1){
+ nested:for(var index_n=0;index_n<=index;index_n++){
+ if(index*index_n == 6)continue nonexist;
+ __str+=""+index+index_n;
+ }
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T1.js
new file mode 100644
index 000000000..192f1ebd5
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T1.js
@@ -0,0 +1,21 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "continue" and (Evaluate Statement).target is in the current label set, iteration of labeled loop breaks
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A11_T1.js
+ * @description Simple test of continue loop with using "continue"
+ */
+
+__str=""
+
+for(index=0; index<10; index+=1) {
+ if (index<5)continue;
+ __str+=index;
+}
+
+if (__str!=="56789") {
+ $ERROR('#1: __str === "56789". Actual: __str ==='+ __str );
+}
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T2.js
new file mode 100644
index 000000000..cdc606b5c
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T2.js
@@ -0,0 +1,63 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "continue" and (Evaluate Statement).target is in the current label set, iteration of labeled loop breaks
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A11_T2.js
+ * @description Embedded loops
+ */
+
+__str="";
+
+outer : for(index=0; index<4; index+=1) {
+ nested : for(index_n=0; index_n<=index; index_n++) {
+ if (index*index_n == 6)continue nested;
+ __str+=""+index+index_n;
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+if (__str !== "001011202122303133") {
+ $ERROR('#1: __str === "001011202122303133". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+__str="";
+
+outer : for(index=0; index<4; index+=1) {
+ nested : for(index_n=0; index_n<=index; index_n++) {
+ if (index*index_n == 6)continue outer;
+ __str+=""+index+index_n;
+ }
+}
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+if (__str !== "0010112021223031") {
+ $ERROR('#2: __str === "0010112021223031". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+__str="";
+
+outer : for(index=0; index<4; index+=1) {
+ nested : for(index_n=0; index_n<=index; index_n++) {
+ if (index*index_n == 6)continue ;
+ __str+=""+index+index_n;
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#3
+if (__str !== "001011202122303133") {
+ $ERROR('#3: __str === "001011202122303133". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T3.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T3.js
new file mode 100644
index 000000000..2807bc86f
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A11_T3.js
@@ -0,0 +1,27 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "continue" and (Evaluate Statement).target is in the current label set, iteration of labeled loop breaks
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A11_T3.js
+ * @description Trying to continue non-existent label
+ * @negative
+ */
+
+__str="";
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#
+outer:for(index=0;index<4;index+=1){
+ nested:for(index_n=0;index_n<=index;index_n++){
+ if(index*index_n == 6)continue nonexist;
+ __str+=""+index+index_n;
+ }
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T1.js
new file mode 100644
index 000000000..48fc3b30c
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T1.js
@@ -0,0 +1,21 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "break" and (Evaluate Statement).target is in the current label set, (normal, (Evaluate Statement), empty) is returned while evaluating a "var-loop"
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A12.1_T1.js
+ * @description Breaking a loop with "break"
+ */
+
+__str=""
+
+for(var index=0; index<10; index+=1) {
+ if (index>5)break;
+ __str+=index;
+}
+
+if (__str!=="012345") {
+ $ERROR('#1: __str === "012345". Actual: __str ==='+ __str );
+}
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T2.js
new file mode 100644
index 000000000..939fd991d
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T2.js
@@ -0,0 +1,64 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "break" and (Evaluate Statement).target is in the current label set, (normal, (Evaluate Statement), empty) is returned while evaluating a "var-loop"
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A12.1_T2.js
+ * @description Embedded loops
+ */
+
+__str="";
+
+outer : for(var index=0; index<4; index+=1) {
+ nested : for(var index_n=0; index_n<=index; index_n++) {
+ if (index*index_n >= 4)break nested;
+ __str+=""+index+index_n;
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+if (__str !== "00101120213031") {
+ $ERROR('#1: __str === "00101120213031". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+__str="";
+
+outer : for(var index=0; index<4; index+=1) {
+ nested : for(var index_n=0; index_n<=index; index_n++) {
+ if (index*index_n >= 4)break outer;
+ __str+=""+index+index_n;
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+if (__str !== "0010112021") {
+ $ERROR('#2: __str === "0010112021". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+__str="";
+
+outer : for(var index=0; index<4; index+=1) {
+ nested : for(var index_n=0; index_n<=index; index_n++) {
+ if (index*index_n >= 4)break ;
+ __str+=""+index+index_n;
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#3
+if (__str !== "00101120213031") {
+ $ERROR('#3: __str === "00101120213031". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T3.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T3.js
new file mode 100644
index 000000000..96a5accd9
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12.1_T3.js
@@ -0,0 +1,24 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "break" and (Evaluate Statement).target is in the current label set, (normal, (Evaluate Statement), empty) is returned while evaluating a "var-loop"
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A12.1_T3.js
+ * @description Trying to break non-existent label
+ * @negative
+ */
+
+__str="";
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+outer:for(var index=0;index<4;index+=1){
+ nested:for(var index_n=0;index_n<=index;index_n++){
+ if(index*index_n >= 4)break nonexist;
+ __str+=""+index+index_n;
+ }
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T1.js
new file mode 100644
index 000000000..55031321d
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T1.js
@@ -0,0 +1,21 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "break" and (Evaluate Statement).target is in the current label set, (normal, (Evaluate Statement), empty) is returned while evaluating a loop
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A12_T1.js
+ * @description Breaking a loop with "break"
+ */
+
+__str=""
+
+for(index=0; index<10; index+=1) {
+ if (index>5)break;
+ __str+=index;
+}
+
+if (__str!=="012345") {
+ $ERROR('#1:__str === "012345". Actual: __str ==='+__str );
+}
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T2.js
new file mode 100644
index 000000000..e97dc7da3
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T2.js
@@ -0,0 +1,64 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "break" and (Evaluate Statement).target is in the current label set, (normal, (Evaluate Statement), empty) is returned while evaluating a loop
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A12_T2.js
+ * @description Embedded loops
+ */
+
+__str="";
+
+outer : for(index=0; index<4; index+=1) {
+ nested : for(index_n=0; index_n<=index; index_n++) {
+ if (index*index_n >= 4)break nested;
+ __str+=""+index+index_n;
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+if (__str !== "00101120213031") {
+ $ERROR('#1: __str === "00101120213031". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+__str="";
+
+outer : for(index=0; index<4; index+=1) {
+ nested : for(index_n=0; index_n<=index; index_n++) {
+ if (index*index_n >= 4)break outer;
+ __str+=""+index+index_n;
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+if (__str !== "0010112021") {
+ $ERROR('#2: __str === "0010112021". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+__str="";
+
+outer : for(index=0; index<4; index+=1) {
+ nested : for(index_n=0; index_n<=index; index_n++) {
+ if (index*index_n >= 4)break ;
+ __str+=""+index+index_n;
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#3
+if (__str !== "00101120213031") {
+ $ERROR('#3: __str === "00101120213031". Actual: __str ==='+ __str );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T3.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T3.js
new file mode 100644
index 000000000..67fd236cd
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A12_T3.js
@@ -0,0 +1,27 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * If (Evaluate Statement).type is "break" and (Evaluate Statement).target is in the current label set, (normal, (Evaluate Statement), empty) is returned while evaluating a loop
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A12_T3.js
+ * @description Trying to break non-existent label
+ * @negative
+ */
+
+__str="";
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#4
+outer:for(index=0;index<4;index+=1){
+ nested:for(index_n=0;index_n<=index;index_n++){
+ if(index*index_n >= 4)break nonexist;
+ __str+=""+index+index_n;
+ }
+};
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A13.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A13.js
new file mode 100644
index 000000000..452902537
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A13.js
@@ -0,0 +1,25 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * VariableDeclaration in "var VariableDeclarationListNoIn" of for IterationStatement is allowed
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A13.js
+ * @description Declaring variable in "for" ExpressionNoIn
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+try {
+ index = index;
+} catch (e) {
+ $ERROR('#1: VariableDeclaration in "var VariableDeclarationListNoIn" of for IterationStatement is allowed');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+for(var index=0; index<6; index++) {
+ ;
+}
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A14.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A14.js
new file mode 100644
index 000000000..182482dd9
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A14.js
@@ -0,0 +1,46 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * The production IterationStatement: "for (var VariableDeclarationListNoIn; Expression; Expression) Statement"
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A14.js
+ * @description Using +,*,/, as the second Expression
+ */
+
+//CHECK#1
+for(var i=0;i<10;i++){}
+if (i!==10) $ERROR('#1: i === 10. Actual: i ==='+ i );
+
+//CHECK#2
+var j=0;
+for(var i=1;i<10;i*=2){
+ j++;
+}
+if (i!==16) $ERROR('#2.1: i === 16. Actual: i ==='+ i );
+if (j!==4) $ERROR('#2.2: j === 4. Actual: j ==='+ j );
+
+//CHECK#3
+var j=0;
+for(var i=16;i>1;i=i/2){
+ j++;
+}
+if (i!==1) $ERROR('#3.1: i === 1. Actual: i ==='+ i );
+if (j!==4) $ERROR('#3.2: j === 4. Actual: j ==='+ j );
+
+//CHECK#4
+var j=0;
+for(var i=10;i>1;i--){
+ j++;
+}
+if (i!==1) $ERROR('#4.1: i === 1. Actual: i ==='+ i );
+if (j!==9) $ERROR('#4.2: j === 9. Actual: j ==='+ j );
+
+//CHECK#5
+var j=0;
+for(var i=2;i<10;i*=i){
+ j++;
+}
+if (i!==16) $ERROR('#5.1: i === 16. Actual: i ==='+ i );
+if (j!==2) $ERROR('#5.2: j === 2. Actual: j ==='+ j );
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A15.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A15.js
new file mode 100644
index 000000000..4ec6147b9
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A15.js
@@ -0,0 +1,24 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * The production IterationStatement: "for (var VariableDeclarationListNoIn; Expression; Expression) Statement"
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A15.js
+ * @description Statement must be evaluated before second Expression is evaluated
+ */
+
+//CHECK#1
+for(var i=0;i<10;i++){
+ i*=2;
+ break;
+}
+if (i!==0) $ERROR('#1: i === 0. Actual: i ==='+ i );
+
+//CHECK#2
+for(var i=0;i<10;i++){
+ i*=2;
+ if (i===3) $ERROR('#2: i !== 3');
+}
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.1.js
new file mode 100644
index 000000000..78372a2d7
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.1.js
@@ -0,0 +1,25 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * While evaluating "for (ExpressionNoIn ; ; Expression) Statement", Statement is evaulated first
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A2.1.js
+ * @description Using "(function(){throw "NoInExpression"})()" as ExpressionNoIn
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+try {
+ for((function(){throw "NoInExpression"})(); ;(function(){throw "SecondExpression"})()) {
+ throw "Statement";
+ }
+ $ERROR('#1: (function(){throw "NoInExpression"})() lead to throwing exception');
+} catch (e) {
+ if (e !== "NoInExpression") {
+ $ERROR('#2: When for (ExpressionNoIn ; ; Expression) Statement is evaluated NoInExpression evaluates first');
+ }
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.2.js
new file mode 100644
index 000000000..f6391e2f7
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.2.js
@@ -0,0 +1,25 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * While evaluating "for (ExpressionNoIn;;) Statement", Statement is evaulated first
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A2.2.js
+ * @description Using "(function(){throw "NoInExpression"})()" as ExpressionNoIn
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+try {
+ for((function(){throw "NoInExpression"})();;) {
+ throw "Statement";
+ }
+ $ERROR('#1: (function(){throw "NoInExpression"})() lead to throwing exception');
+} catch (e) {
+ if (e !== "NoInExpression") {
+ $ERROR('#1: When for (ExpressionNoIn ; ; ) Statement is evaluated NoInExpression evaluates first');
+ }
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.js
new file mode 100644
index 000000000..86718d9d1
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A2.js
@@ -0,0 +1,33 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * While evaluating "for (ExpressionNoIn; Expression; Expression) Statement", ExpressionNoIn is evaulated first
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A2.js
+ * @description Using "(function(){throw "NoInExpression"})()" as ExpressionNoIn
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+try {
+ for((function(){throw "NoInExpression";})(); (function(){throw "FirstExpression";})(); (function(){throw "SecondExpression";})()) {
+ var in_for = "reached";
+ }
+ $ERROR('#1: (function(){throw "NoInExpression";})() lead to throwing exception');
+} catch (e) {
+ if (e !== "NoInExpression") {
+ $ERROR('#1: When for (ExpressionNoIn ; Expression ; Expression) Statement is evaluated ExpressionNoIn evaluates first');
+ }
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+if (in_for !== undefined) {
+ $ERROR('#2: in_for === undefined. Actual: in_for ==='+ in_for );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A3.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A3.js
new file mode 100644
index 000000000..2c46dbfbb
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A3.js
@@ -0,0 +1,41 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * While evaluating "for (ExpressionNoIn; FirstExpression; SecondExpression) Statement", ExpressionNoIn is evaulated first, FirstExpressoin is evaluated second
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A3.js
+ * @description Using "(function(){throw "FirstExpression"})()" as FirstExpression
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+try {
+ for((function(){__in__NotInExpression__ = "checked";__in__NotInExpression__2 = "passed";})(); (function(){throw "FirstExpression"})(); (function(){throw "SecondExpression"})()) {
+ __in__for="reached";
+ }
+ $ERROR('#1: (function(){throw "SecondExpression"} lead to throwing exception');
+} catch (e) {
+ if (e !== "FirstExpression") {
+ $ERROR('#1: When for (ExpressionNoIn ; FirstExpression ; SecondExpression) Statement is evaluated first evaluates ExpressionNoIn then FirstExpression');
+ }
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+if ((__in__NotInExpression__ !== "checked")&(__in__NotInExpression__2!=="passed")) {
+ $ERROR('#2: (__in__NotInExpression__ === "checked")&(__in__NotInExpression__2==="passed")');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#3
+if (typeof __in__for !== "undefined") {
+ $ERROR('#3: typeof __in__for === "undefined". Actual: typeof __in__for ==='+ typeof __in__for );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4.1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4.1.js
new file mode 100644
index 000000000..a64935274
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4.1.js
@@ -0,0 +1,22 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * "in"-expression is not allowed as a ExpressionNoIn in "for (ExpressionNoIn; FirstExpression; SecondExpression) Statement" IterationStatement
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A4.1.js
+ * @description Checking if execution of "for (var a in arr;1;){}" fails
+ * @negative
+ */
+
+arr = [1,2,3,4,5];
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for (var a in arr;1;){
+ break;
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4_T1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4_T1.js
new file mode 100644
index 000000000..48e56c4b1
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4_T1.js
@@ -0,0 +1,22 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * "in"-expression is not allowed as a ExpressionNoIn in "for (ExpressionNoIn; FirstExpression; SecondExpression) Statement" IterationStatement
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A4_T1.js
+ * @description Checking if execution of "for (a in arr;1;){}" fails
+ * @negative
+ */
+
+arr = [1,2,3,4,5];
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for (a in arr;1;){
+ break;
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4_T2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4_T2.js
new file mode 100644
index 000000000..2a292a808
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A4_T2.js
@@ -0,0 +1,22 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * "in"-expression is not allowed as a ExpressionNoIn in "for (ExpressionNoIn; FirstExpression; SecondExpression) Statement" IterationStatement
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A4_T2.js
+ * @description Checking if execution of "for (1 in arr;1;){}" fails
+ * @negative
+ */
+
+arr = [1,2,3,4,5];
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for(1 in arr;1;) {
+ break;
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A5.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A5.js
new file mode 100644
index 000000000..6cab0f017
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A5.js
@@ -0,0 +1,42 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * "in"-expression wrapped into "eval" statement is allowed as a ExpressionNoIn in "for (ExpressionNoIn; FirstExpression; SecondExpression) Statement" IterationStatement
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A5.js
+ * @description Using eval "for(eval("i in arr");1;)"
+ */
+
+arr = [1,2,3,4,5];
+i = 1;
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+try {
+ for(eval("i in arr");1;) {break;};
+} catch (e) {
+ $ERROR('#1.1: for(eval("i in arr");1;) {break;}; does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+try {
+ for(eval("var i = 1 in arr");1;) {break;};
+} catch (e) {
+ $ERROR('#2.1: for(eval("var i = 1 in arr");1;) {break;}; does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#3
+try {
+ for(eval("1 in arr");1;) {break;};
+} catch (e) {
+ $ERROR('#3.1: for(eval("1 in arr");1;) {break;}; does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A6.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A6.js
new file mode 100644
index 000000000..1dfd5b457
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A6.js
@@ -0,0 +1,33 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * While evaluating "for ( ; ; Expression) Statement", Statement is evaluated first and then Expression is evaluated
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A6.js
+ * @description Using "(function(){throw "SecondExpression";})()" as an Expression
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+try {
+ for(;;(function(){throw "SecondExpression";})()){
+ var __in__for = "reached";
+ }
+ $ERROR('#1: (function(){throw "SecondExpression"}() lead to throwing exception');
+} catch (e) {
+ if (e !== "SecondExpression") {
+ $ERROR('#1: When for ( ; ; Expression) Statement is evaluated Statement evaluates first then Expression evaluates');
+ }
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#2
+if (__in__for !== "reached") {
+ $ERROR('#2: __in__for === "reached". Actual: __in__for ==='+ __in__for );
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7.1_T1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7.1_T1.js
new file mode 100644
index 000000000..f8b2fdbd0
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7.1_T1.js
@@ -0,0 +1,18 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Only three expressions and two semicolons in "for(with var)" braces are allowed.
+ * Appearing of for (ExpressionNoIn_opt ; Expression_opt ; Expression_opt; Expression_opt; Expression_opt;) statement leads to SyntaxError
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A7.1_T1.js
+ * @description Checking if execution of "for(var index=0; index<10; index++; index--)" fails
+ * @negative
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for(var index=0; index<10; index++; index--);
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7.1_T2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7.1_T2.js
new file mode 100644
index 000000000..550b14b19
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7.1_T2.js
@@ -0,0 +1,18 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Only three expressions and two semicolons in "for(with var)" braces are allowed.
+ * Appearing of for (ExpressionNoIn_opt ; Expression_opt ; Expression_opt; Expression_opt; Expression_opt;) statement leads to SyntaxError
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A7.1_T2.js
+ * @description Checking if execution of "for(var index=0; index<10; index+=4; index++; index--)" fails
+ * @negative
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for(var index=0; index<10; index+=4; index++; index--) ;
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7_T1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7_T1.js
new file mode 100644
index 000000000..39dcc1c6a
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7_T1.js
@@ -0,0 +1,18 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Only three expressions and two semicolons in "for" braces are allowed.
+ * Appearing of for (ExpressionNoIn_opt ; Expression_opt ; Expression_opt; Expression_opt; Expression_opt;) statement leads to SyntaxError
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A7_T1.js
+ * @description Checking if execution of "for(index=0; index<10; index++; index--)" fails
+ * @negative
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for(index=0; index<10; index++; index--) ;
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7_T2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7_T2.js
new file mode 100644
index 000000000..2f22dbf3c
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A7_T2.js
@@ -0,0 +1,18 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Only three expressions and two semicolons in "for" braces are allowed.
+ * Appearing of for (ExpressionNoIn_opt ; Expression_opt ; Expression_opt; Expression_opt; Expression_opt;) statement leads to SyntaxError
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A7_T2.js
+ * @description Checking if execution of "for(index=0; index<10; index+=4; index++; index--)" fails
+ * @negative
+ */
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for(index=0; index<10; index+=4; index++; index--) ;
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T1.js
new file mode 100644
index 000000000..ddd3c30e4
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T1.js
@@ -0,0 +1,19 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Blocks within "for(with var)" braces are not allowed
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A8.1_T1.js
+ * @description Checking if execution of "for(var index=0; index<100; {index++; index*2;}) { arr.add(""+index);}" fails
+ * @negative
+ */
+
+var arr = [];
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for(var index=0; index<100; {index++; index*2;}) { arr.add(""+index);};
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T2.js
new file mode 100644
index 000000000..81cbed22b
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T2.js
@@ -0,0 +1,22 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Blocks within "for(with var)" braces are not allowed
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A8.1_T2.js
+ * @description Checking if execution of "for(var index=0; {index++;index<100;}; index*2;) { arr.add(""+index);}" fails
+ * @negative
+ */
+
+var arr = [];
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for(var index=0; {index++;index<100;}; index*2;) { arr.add(""+index);};
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T3.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T3.js
new file mode 100644
index 000000000..8c26060e3
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8.1_T3.js
@@ -0,0 +1,22 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Blocks within "for(with var)" braces are not allowed
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A8.1_T3.js
+ * @description Checking if execution of "for({var index=0; index+=1;} index++<=10; index*2;) { arr.add(""+index);}" fails
+ * @negative
+ */
+
+var arr = [];
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#3
+for({var index=0; index+=1;} index++<=10; index*2;) { arr.add(""+index);};
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T1.js
new file mode 100644
index 000000000..8f9ce29d6
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T1.js
@@ -0,0 +1,19 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Blocks within "for" braces are not allowed
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A8_T1.js
+ * @description Checking if execution of "for(index=0; index<100; {index++; index*2;}) { arr.add(""+index);}" fails
+ * @negative
+ */
+
+var arr = [];
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for(index=0; index<100; {index++; index*2;}) { arr.add(""+index);};
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T2.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T2.js
new file mode 100644
index 000000000..406d23bbb
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T2.js
@@ -0,0 +1,19 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Blocks within "for" braces are not allowed
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A8_T2.js
+ * @description Checking if execution of "for(index=0; {index++;index<100;}; index*2;) { arr.add(""+index);}" fails
+ * @negative
+ */
+
+var arr = [];
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for(index=0; {index++;index<100;}; index*2;) { arr.add(""+index);};
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T3.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T3.js
new file mode 100644
index 000000000..9843a3229
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A8_T3.js
@@ -0,0 +1,22 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * Blocks within "for" braces are not allowed
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A8_T3.js
+ * @description Checking if execution of "for({index=0; index+=1;} index++<=10; index*2;) { arr.add(""+index);}" fails
+ * @negative
+ */
+
+var arr = [];
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#1
+for({index=0; index+=1;} index++<=10; index*2;) { arr.add(""+index);};
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A9.1.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A9.1.js
new file mode 100644
index 000000000..c2031c9ab
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A9.1.js
@@ -0,0 +1,25 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * The result of evaluating "for( ExpNoIn;Exp;Exp)" loop is returning (normal, evalValue, empty)
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A9.1.js
+ * @description Using eval
+ */
+
+supreme=5;
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#
+try {
+ var __evaluated = eval("for(count=0;;) {if (count===supreme)break;else count++; }");
+ if (__evaluated !== 4) {
+ $ERROR('#1: __evaluated === 4. Actual: __evaluated ==='+ __evaluated );
+ }
+} catch (e) {
+ $ERROR('#1: var __evaluated = eval("for(count=0;;) {if (count===supreme)break;else count++; }"); does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A9.js b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A9.js
new file mode 100644
index 000000000..11b88316f
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/S12.6.3_A9.js
@@ -0,0 +1,25 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * The result of evaluating "for(var ExpNoIn;Exp;Exp)" loop is returning (normal, evalValue, empty)
+ *
+ * @path ch12/12.6/12.6.3/S12.6.3_A9.js
+ * @description Using eval
+ */
+
+supreme=5;
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#
+try {
+ var __evaluated = eval("for(var count=0;;) {if (count===supreme)break;else count++; }");
+ if (__evaluated !== 4) {
+ $ERROR('#1: __evaluated === 4. Actual: __evaluated ==='+ __evaluated );
+ }
+} catch (e) {
+ $ERROR('#1: var __evaluated = eval("for(var count=0;;) {if (count===supreme)break;else count++; }"); does not lead to throwing exception');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/browser.js b/js/src/tests/test262/ch12/12.6/12.6.3/browser.js
new file mode 100644
index 000000000..e69de29bb
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/browser.js
diff --git a/js/src/tests/test262/ch12/12.6/12.6.3/shell.js b/js/src/tests/test262/ch12/12.6/12.6.3/shell.js
new file mode 100644
index 000000000..e69de29bb
--- /dev/null
+++ b/js/src/tests/test262/ch12/12.6/12.6.3/shell.js