Merge pull request #252 from anba/issue-35/builtins-global-properties

Fix strict mode errors in built-ins/{isFinite, isNaN, parseFloat, parseI...
This commit is contained in:
Brian Terlson 2015-04-30 09:47:44 -07:00
commit 76958cd940
10 changed files with 6 additions and 9 deletions

View File

@ -14,7 +14,7 @@ if (isFinite.propertyIsEnumerable('length') !== false) {
//CHECK#2 //CHECK#2
var result = true; var result = true;
for (p in isFinite){ for (var p in isFinite){
if (p === "length") { if (p === "length") {
result = false; result = false;
} }

View File

@ -5,7 +5,6 @@
info: The length property of isFinite does not have the attribute DontDelete info: The length property of isFinite does not have the attribute DontDelete
es5id: 15.1.2.5_A2.2 es5id: 15.1.2.5_A2.2
description: Checking use hasOwnProperty, delete description: Checking use hasOwnProperty, delete
flags: [noStrict]
includes: [$FAIL.js] includes: [$FAIL.js]
---*/ ---*/

View File

@ -14,7 +14,7 @@ if (this.propertyIsEnumerable('isFinite') !== false) {
//CHECK#2 //CHECK#2
var result = true; var result = true;
for (p in this){ for (var p in this){
if (p === "isFinite") { if (p === "isFinite") {
result = false; result = false;
} }

View File

@ -14,7 +14,7 @@ if (isNaN.propertyIsEnumerable('length') !== false) {
//CHECK#2 //CHECK#2
var result = true; var result = true;
for (p in isNaN){ for (var p in isNaN){
if (p === "length") { if (p === "length") {
result = false; result = false;
} }

View File

@ -5,7 +5,6 @@
info: The length property of isNaN does not have the attribute DontDelete info: The length property of isNaN does not have the attribute DontDelete
es5id: 15.1.2.4_A2.2 es5id: 15.1.2.4_A2.2
description: Checking use hasOwnProperty, delete description: Checking use hasOwnProperty, delete
flags: [noStrict]
includes: [$FAIL.js] includes: [$FAIL.js]
---*/ ---*/

View File

@ -14,7 +14,7 @@ if (this.propertyIsEnumerable('isNaN') !== false) {
//CHECK#2 //CHECK#2
var result = true; var result = true;
for (p in this){ for (var p in this){
if (p === "isNaN") { if (p === "isNaN") {
result = false; result = false;
} }

View File

@ -5,7 +5,6 @@
info: The length property of parseFloat does not have the attribute DontDelete info: The length property of parseFloat does not have the attribute DontDelete
es5id: 15.1.2.3_A7.2 es5id: 15.1.2.3_A7.2
description: Checking use hasOwnProperty, delete description: Checking use hasOwnProperty, delete
flags: [noStrict]
includes: [$FAIL.js] includes: [$FAIL.js]
---*/ ---*/

View File

@ -5,7 +5,6 @@
info: The length property of parseInt does not have the attribute DontDelete info: The length property of parseInt does not have the attribute DontDelete
es5id: 15.1.2.2_A9.2 es5id: 15.1.2.2_A9.2
description: Checking use hasOwnProperty, delete description: Checking use hasOwnProperty, delete
flags: [noStrict]
includes: [$FAIL.js] includes: [$FAIL.js]
---*/ ---*/

View File

@ -9,6 +9,7 @@ es5id: 15.1.1.3-3
description: > description: >
undefined is not writable, simple assignment should return the undefined is not writable, simple assignment should return the
rval value (11.13.1-6) rval value (11.13.1-6)
flags: [noStrict]
includes: [runTestCase.js] includes: [runTestCase.js]
---*/ ---*/

View File

@ -8,7 +8,7 @@ description: Use for-in statement
---*/ ---*/
// CHECK#1 // CHECK#1
for (prop in this) { for (var prop in this) {
if (prop === "undefined") { if (prop === "undefined") {
$ERROR('#1: The undefined is DontEnum'); $ERROR('#1: The undefined is DontEnum');
} }