mirror of
https://github.com/tc39/test262.git
synced 2025-04-08 19:35:28 +02:00
chore: migrate $ERROR -> throw new Test262Error in test/language/a* (#3095)
This commit is contained in:
parent
805e081783
commit
582d5e57ca
@ -15,19 +15,19 @@ function f1() {
|
||||
this.constructor.prototype.arguments = ARG_STRING;
|
||||
return arguments;
|
||||
}
|
||||
|
||||
|
||||
//CHECK#1
|
||||
if ((new f1(1,2,3,4,5)).length !== 5)
|
||||
$ERROR('#1: (new f1(1,2,3,4,5)).length===5, where f1 returns "arguments" that is set to "'+ ARG_STRING + '"');
|
||||
throw new Test262Error('#1: (new f1(1,2,3,4,5)).length===5, where f1 returns "arguments" that is set to "'+ ARG_STRING + '"');
|
||||
|
||||
//CHECK#2
|
||||
//CHECK#2
|
||||
if ((new f1(1,2,3,4,5))[3] !== 4)
|
||||
$ERROR('#2: (new f1(1,2,3,4,5))[3]===4, where f1 returns "arguments" that is set to "'+ ARG_STRING + '"');
|
||||
throw new Test262Error('#2: (new f1(1,2,3,4,5))[3]===4, where f1 returns "arguments" that is set to "'+ ARG_STRING + '"');
|
||||
|
||||
//CHECK#3
|
||||
var x = new f1(1,2,3,4,5);
|
||||
var x = new f1(1,2,3,4,5);
|
||||
if (delete x[3] !== true)
|
||||
$ERROR('#3.1: Function parameters have attribute {DontDelete}');
|
||||
|
||||
throw new Test262Error('#3.1: Function parameters have attribute {DontDelete}');
|
||||
|
||||
if (x[3] === 4)
|
||||
$ERROR('#3.2: Function parameters have attribute {DontDelete}');
|
||||
throw new Test262Error('#3.2: Function parameters have attribute {DontDelete}');
|
||||
|
@ -18,7 +18,7 @@ try{
|
||||
var x = f1();
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments doesn't exists");
|
||||
throw new Test262Error("#1: arguments doesn't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@ -30,5 +30,5 @@ try{
|
||||
var x = f2();
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#2: arguments doesn't exists");
|
||||
throw new Test262Error("#2: arguments doesn't exists");
|
||||
}
|
||||
|
@ -16,20 +16,20 @@ function f1(){
|
||||
}
|
||||
try{
|
||||
if(f1() !== Object.prototype){
|
||||
$ERROR('#1: arguments.constructor.prototype === Object.prototype');
|
||||
throw new Test262Error('#1: arguments.constructor.prototype === Object.prototype');
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments doesn't exists");
|
||||
throw new Test262Error("#1: arguments doesn't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
var f2 = function(){return arguments.constructor.prototype;};
|
||||
try{
|
||||
if(f2() !== Object.prototype){
|
||||
$ERROR('#2: arguments.constructor.prototype === Object.prototype');
|
||||
throw new Test262Error('#2: arguments.constructor.prototype === Object.prototype');
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#2: arguments doesn't exists");
|
||||
throw new Test262Error("#2: arguments doesn't exists");
|
||||
}
|
||||
|
@ -15,20 +15,20 @@ function f1(){
|
||||
}
|
||||
try{
|
||||
if(f1() !== true){
|
||||
$ERROR("#1: arguments object doesn't contains property 'callee'");
|
||||
throw new Test262Error("#1: arguments object doesn't contains property 'callee'");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments object doesn't exists");
|
||||
throw new Test262Error("#1: arguments object doesn't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
var f2 = function(){return arguments.hasOwnProperty("callee");};
|
||||
try{
|
||||
if(f2() !== true){
|
||||
$ERROR("#2: arguments object doesn't contains property 'callee'");
|
||||
throw new Test262Error("#2: arguments object doesn't contains property 'callee'");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#2: arguments object doesn't exists");
|
||||
throw new Test262Error("#2: arguments object doesn't exists");
|
||||
}
|
||||
|
@ -21,11 +21,11 @@ function f1(){
|
||||
|
||||
try{
|
||||
if(!f1()){
|
||||
$ERROR("#1: A property callee don't have attribute { DontEnum }");
|
||||
throw new Test262Error("#1: A property callee don't have attribute { DontEnum }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments object don't exists");
|
||||
throw new Test262Error("#1: arguments object don't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@ -40,9 +40,9 @@ var f2 = function(){
|
||||
|
||||
try{
|
||||
if(!f2()){
|
||||
$ERROR("#2: A property callee don't have attribute { DontEnum }");
|
||||
throw new Test262Error("#2: A property callee don't have attribute { DontEnum }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#2: arguments object don't exists");
|
||||
throw new Test262Error("#2: arguments object don't exists");
|
||||
}
|
||||
|
@ -17,11 +17,11 @@ function f1(){
|
||||
|
||||
try{
|
||||
if(!f1()){
|
||||
$ERROR("#1: A property callee have attribute { DontDelete }");
|
||||
throw new Test262Error("#1: A property callee have attribute { DontDelete }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments object don't exists");
|
||||
throw new Test262Error("#1: arguments object don't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@ -31,9 +31,9 @@ var f2 = function(){
|
||||
|
||||
try{
|
||||
if(!f2()){
|
||||
$ERROR("#2: A property callee have attribute { DontDelete }");
|
||||
throw new Test262Error("#2: A property callee have attribute { DontDelete }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#2: arguments object don't exists");
|
||||
throw new Test262Error("#2: arguments object don't exists");
|
||||
}
|
||||
|
@ -19,11 +19,11 @@ function f1(){
|
||||
|
||||
try{
|
||||
if(f1().callee !== str){
|
||||
$ERROR("#1: A property callee have attribute { ReadOnly }");
|
||||
throw new Test262Error("#1: A property callee have attribute { ReadOnly }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments object don't exists");
|
||||
throw new Test262Error("#1: arguments object don't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@ -33,9 +33,9 @@ var f2 = function(){
|
||||
}
|
||||
try{
|
||||
if(f2().callee !== str){
|
||||
$ERROR("#2: A property callee have attribute { ReadOnly }");
|
||||
throw new Test262Error("#2: A property callee have attribute { ReadOnly }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#2: arguments object don't exists");
|
||||
throw new Test262Error("#2: arguments object don't exists");
|
||||
}
|
||||
|
@ -17,11 +17,11 @@ function f1(){
|
||||
|
||||
try{
|
||||
if(f1 !== f1()){
|
||||
$ERROR('#1: arguments.callee === f1');
|
||||
throw new Test262Error('#1: arguments.callee === f1');
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments object doesn't exists");
|
||||
throw new Test262Error("#1: arguments object doesn't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@ -29,9 +29,9 @@ var f2 = function(){return arguments.callee;};
|
||||
|
||||
try{
|
||||
if(f2 !== f2()){
|
||||
$ERROR('#2: arguments.callee === f2');
|
||||
throw new Test262Error('#2: arguments.callee === f2');
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments object doesn't exists");
|
||||
throw new Test262Error("#1: arguments object doesn't exists");
|
||||
}
|
||||
|
@ -15,20 +15,20 @@ function f1(){
|
||||
}
|
||||
try{
|
||||
if(f1() !== true){
|
||||
$ERROR("#1: arguments object doesn't contains property 'length'");
|
||||
throw new Test262Error("#1: arguments object doesn't contains property 'length'");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments object doesn't exists");
|
||||
throw new Test262Error("#1: arguments object doesn't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
var f2 = function(){return arguments.hasOwnProperty("length");};
|
||||
try{
|
||||
if(f2() !== true){
|
||||
$ERROR("#2: arguments object doesn't contains property 'length'");
|
||||
throw new Test262Error("#2: arguments object doesn't contains property 'length'");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#2: arguments object doesn't exists");
|
||||
throw new Test262Error("#2: arguments object doesn't exists");
|
||||
}
|
||||
|
@ -21,11 +21,11 @@ function f1(){
|
||||
|
||||
try{
|
||||
if(!f1()){
|
||||
$ERROR("#1: A property length don't have attribute { DontEnum }");
|
||||
throw new Test262Error("#1: A property length don't have attribute { DontEnum }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments object don't exists");
|
||||
throw new Test262Error("#1: arguments object don't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@ -40,9 +40,9 @@ var f2 = function(){
|
||||
|
||||
try{
|
||||
if(!f2()){
|
||||
$ERROR("#2: A property length don't have attribute { DontEnum }");
|
||||
throw new Test262Error("#2: A property length don't have attribute { DontEnum }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#2: arguments object don't exists");
|
||||
throw new Test262Error("#2: arguments object don't exists");
|
||||
}
|
||||
|
@ -11,28 +11,28 @@ description: Checking if deleting arguments.length property fails
|
||||
|
||||
//CHECK#1
|
||||
function f1(){
|
||||
return (delete arguments.length);
|
||||
return (delete arguments.length);
|
||||
}
|
||||
|
||||
try{
|
||||
if(!f1()){
|
||||
$ERROR("#1: A property length have attribute { DontDelete }");
|
||||
throw new Test262Error("#1: A property length have attribute { DontDelete }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments object don't exists");
|
||||
throw new Test262Error("#1: arguments object don't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
var f2 = function(){
|
||||
return (delete arguments.length);
|
||||
return (delete arguments.length);
|
||||
}
|
||||
|
||||
try{
|
||||
if(!f2()){
|
||||
$ERROR("#2: A property length have attribute { DontDelete }");
|
||||
throw new Test262Error("#2: A property length have attribute { DontDelete }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#2: arguments object don't exists");
|
||||
throw new Test262Error("#2: arguments object don't exists");
|
||||
}
|
||||
|
@ -18,11 +18,11 @@ function f1(){
|
||||
|
||||
try{
|
||||
if(f1().length !== str){
|
||||
$ERROR("#1: A property length have attribute { ReadOnly }");
|
||||
throw new Test262Error("#1: A property length have attribute { ReadOnly }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#1: arguments object don't exists");
|
||||
throw new Test262Error("#1: arguments object don't exists");
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@ -32,9 +32,9 @@ var f2 = function(){
|
||||
};
|
||||
try{
|
||||
if(f2().length !== str){
|
||||
$ERROR("#2: A property length have attribute { ReadOnly }");
|
||||
throw new Test262Error("#2: A property length have attribute { ReadOnly }");
|
||||
}
|
||||
}
|
||||
catch(e){
|
||||
$ERROR("#2: arguments object don't exists");
|
||||
throw new Test262Error("#2: arguments object don't exists");
|
||||
}
|
||||
|
@ -15,52 +15,52 @@ function f1(){
|
||||
|
||||
//CHECK#1
|
||||
if(!(f1() === 0)){
|
||||
$ERROR('#1: argument.length === 0');
|
||||
throw new Test262Error('#1: argument.length === 0');
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
if(!(f1(0) === 1)){
|
||||
$ERROR('#2: argument.length === 1');
|
||||
throw new Test262Error('#2: argument.length === 1');
|
||||
}
|
||||
|
||||
//CHECK#3
|
||||
if(!(f1(0, 1) === 2)){
|
||||
$ERROR('#3: argument.length === 2');
|
||||
throw new Test262Error('#3: argument.length === 2');
|
||||
}
|
||||
|
||||
//CHECK#4
|
||||
if(!(f1(0, 1, 2) === 3)){
|
||||
$ERROR('#4: argument.length === 3');
|
||||
throw new Test262Error('#4: argument.length === 3');
|
||||
}
|
||||
|
||||
//CHECK#5
|
||||
if(!(f1(0, 1, 2, 3) === 4)){
|
||||
$ERROR('#5: argument.length === 4');
|
||||
throw new Test262Error('#5: argument.length === 4');
|
||||
}
|
||||
|
||||
var f2 = function(){return arguments.length;};
|
||||
|
||||
//CHECK#6
|
||||
if(!(f2() === 0)){
|
||||
$ERROR('#6: argument.length === 0');
|
||||
throw new Test262Error('#6: argument.length === 0');
|
||||
}
|
||||
|
||||
//CHECK#7
|
||||
if(!(f2(0) === 1)){
|
||||
$ERROR('#7: argument.length === 1');
|
||||
throw new Test262Error('#7: argument.length === 1');
|
||||
}
|
||||
|
||||
//CHECK#8
|
||||
if(!(f2(0, 1) === 2)){
|
||||
$ERROR('#8: argument.length === 2');
|
||||
throw new Test262Error('#8: argument.length === 2');
|
||||
}
|
||||
|
||||
//CHECK#9
|
||||
if(!(f2(0, 1, 2) === 3)){
|
||||
$ERROR('#9: argument.length === 3');
|
||||
throw new Test262Error('#9: argument.length === 3');
|
||||
}
|
||||
|
||||
//CHECK#10
|
||||
if(!(f2(0, 1, 2, 3) === 4)){
|
||||
$ERROR('#10: argument.length === 4');
|
||||
throw new Test262Error('#10: argument.length === 4');
|
||||
}
|
||||
|
@ -10,9 +10,9 @@ description: Use property arguments
|
||||
function f1() {
|
||||
return arguments;
|
||||
}
|
||||
|
||||
|
||||
//CHECK#1-5
|
||||
for(var i = 1; i < 5; i++){
|
||||
if (f1(1,2,3,4,5)[i] !== (i+1))
|
||||
$ERROR("#"+i+": Returning function's arguments work wrong, f1(1,2,3,4,5)["+i+"] !== "+(i+1));
|
||||
for(var i = 1; i < 5; i++){
|
||||
if (f1(1,2,3,4,5)[i] !== (i+1))
|
||||
throw new Test262Error("#"+i+": Returning function's arguments work wrong, f1(1,2,3,4,5)["+i+"] !== "+(i+1));
|
||||
}
|
||||
|
@ -16,4 +16,4 @@ function test(){
|
||||
a+b
|
||||
}
|
||||
var x=test();
|
||||
if (x!==undefined) $ERROR('#1: Automatic semicolon insertion not work with return');
|
||||
if (x!==undefined) throw new Test262Error('#1: Automatic semicolon insertion not work with return');
|
||||
|
@ -14,4 +14,4 @@ var a=1,b=2,c=3;
|
||||
a=b
|
||||
++c
|
||||
|
||||
if (a!==b) $ERROR('#1: Automatic semicolon insertion not work with ++');
|
||||
if (a!==b) throw new Test262Error('#1: Automatic semicolon insertion not work with ++');
|
||||
|
@ -19,4 +19,4 @@ var a=1,b=2,d=4,e=5;
|
||||
a=b+c
|
||||
(d+e)
|
||||
|
||||
if (a !== 20) $ERROR('#1: Automatic semicolon insertion work wrong');
|
||||
if (a !== 20) throw new Test262Error('#1: Automatic semicolon insertion work wrong');
|
||||
|
@ -13,9 +13,9 @@ label1: for (var i = 0; i <= 0; i++) {
|
||||
if (j === 0) {
|
||||
continue label1;
|
||||
} else {
|
||||
$ERROR('#1: Check continue statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check continue statement for automatic semicolon insertion');
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
@ -23,14 +23,14 @@ var result = false;
|
||||
label2: for (var i = 0; i <= 1; i++) {
|
||||
for (var j = 0; j <= 1; j++) {
|
||||
if (j === 0) {
|
||||
continue
|
||||
label2;
|
||||
continue
|
||||
label2;
|
||||
} else {
|
||||
result = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (result !== true) {
|
||||
$ERROR('#2: Check continue statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#2: Check continue statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -11,5 +11,5 @@ description: Use if (false) x = 1 (without semicolon) and check x
|
||||
var x = 0;
|
||||
if (false) x = 1
|
||||
if (x !== 0) {
|
||||
$ERROR('#1: Check If Statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check If Statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -11,5 +11,5 @@ description: Use if (false) {x = 1} else {x=-1} and check x
|
||||
var x = 0;
|
||||
if (false) {x = 1} else {x = -1}
|
||||
if (x !== -1) {
|
||||
$ERROR('#1: Check If Statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check If Statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -12,5 +12,5 @@ var x = 0;
|
||||
if (false) {{x = 1};}
|
||||
else x = -1
|
||||
if (x !== -1) {
|
||||
$ERROR('#1: Check If Statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check If Statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -12,5 +12,5 @@ var x = 0;
|
||||
if (false)
|
||||
x = 1
|
||||
if (x !== 0) {
|
||||
$ERROR('#1: Check If Statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check If Statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -12,5 +12,5 @@ var x = 0;
|
||||
if (false);
|
||||
x = 1
|
||||
if (x !== 1) {
|
||||
$ERROR('#1: Check If Statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check If Statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -11,5 +11,5 @@ description: Use if (false) x = 1; else x=-1 and check x
|
||||
var x = 0;
|
||||
if (false) x = 1; else x = -1
|
||||
if (x !== -1) {
|
||||
$ERROR('#1: Check If Statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check If Statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -12,5 +12,5 @@ var x = 0;
|
||||
if (false) x = 1
|
||||
else x = -1
|
||||
if (x !== -1) {
|
||||
$ERROR('#1: Check If Statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check If Statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -12,5 +12,5 @@ var x = 0;
|
||||
if (false) x = 1;
|
||||
else x = -1
|
||||
if (x !== -1) {
|
||||
$ERROR('#1: Check If Statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check If Statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -12,5 +12,5 @@ var x = 0;
|
||||
if (false) {x = 1}
|
||||
else x = -1
|
||||
if (x !== -1) {
|
||||
$ERROR('#1: Check If Statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check If Statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -12,19 +12,19 @@ label1: for (var i = 0; i <= 0; i++) {
|
||||
for (var j = 0; j <= 0; j++) {
|
||||
break label1;
|
||||
}
|
||||
$ERROR('#1: Check break statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check break statement for automatic semicolon insertion');
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
var result = false;
|
||||
label2: for (var i = 0; i <= 0; i++) {
|
||||
for (var j = 0; j <= 0; j++) {
|
||||
break
|
||||
break
|
||||
label2;
|
||||
}
|
||||
}
|
||||
result = true;
|
||||
}
|
||||
|
||||
if (result !== true) {
|
||||
$ERROR('#2: Check break statement for automatic semicolon insertion');
|
||||
throw new Test262Error('#2: Check break statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -12,16 +12,16 @@ function f1()
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
if (f1() !== 1) {
|
||||
$ERROR('#1: Check return statement for automatic semicolon insertion');
|
||||
}
|
||||
if (f1() !== 1) {
|
||||
throw new Test262Error('#1: Check return statement for automatic semicolon insertion');
|
||||
}
|
||||
|
||||
//CHECK#2
|
||||
function f2()
|
||||
{
|
||||
return
|
||||
return
|
||||
1;
|
||||
}
|
||||
if (f2() !== undefined) {
|
||||
$ERROR('#2: Check return statement for automatic semicolon insertion');
|
||||
if (f2() !== undefined) {
|
||||
throw new Test262Error('#2: Check return statement for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -13,9 +13,9 @@ var y = 0;
|
||||
x
|
||||
++y
|
||||
if (x !== 0) {
|
||||
$ERROR('#1: Check Prefix Increment Operator for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check Prefix Increment Operator for automatic semicolon insertion');
|
||||
} else {
|
||||
if (y !== 1) {
|
||||
$ERROR('#2: Check Prefix Increment Operator for automatic semicolon insertion');
|
||||
throw new Test262Error('#2: Check Prefix Increment Operator for automatic semicolon insertion');
|
||||
}
|
||||
}
|
||||
|
@ -13,9 +13,9 @@ var y = 1;
|
||||
x
|
||||
--y
|
||||
if (x !== 1) {
|
||||
$ERROR('#1: Check Prefix Decrement Operator for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check Prefix Decrement Operator for automatic semicolon insertion');
|
||||
} else {
|
||||
if (y !== 0) {
|
||||
$ERROR('#1: Check Prefix Decrement Operator for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check Prefix Decrement Operator for automatic semicolon insertion');
|
||||
}
|
||||
}
|
||||
|
@ -14,5 +14,5 @@ function f(t) {
|
||||
var x = 1 + f
|
||||
(2 + 3)
|
||||
if (x !== 6) {
|
||||
$ERROR('#1: Check Function Expression for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check Function Expression for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -13,5 +13,5 @@ description: >
|
||||
var result = function f(o) {o.x = 1; return o;};
|
||||
(new Object()).x;
|
||||
if (typeof result !== "function") {
|
||||
$ERROR('#1: Check Function Expression for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check Function Expression for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -13,5 +13,5 @@ description: >
|
||||
var result = function f(o) {o.x = 1; return o;}
|
||||
(new Object()).x;
|
||||
if (result !== 1) {
|
||||
$ERROR('#1: Check Function Expression for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check Function Expression for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -16,5 +16,5 @@ var x =
|
||||
a
|
||||
|
||||
if (x !== 6) {
|
||||
$ERROR('#1: Check Function Expression for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check Function Expression for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -24,5 +24,5 @@ a
|
||||
()
|
||||
|
||||
if (x !== 7) {
|
||||
$ERROR('#1: Check Function Expression for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check Function Expression for automatic semicolon insertion');
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ y
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#1
|
||||
if ((x!==0)&(y!==1)) {
|
||||
$ERROR('#1: Check Postfix Increment Operator for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check Postfix Increment Operator for automatic semicolon insertion');
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
@ -29,7 +29,7 @@ x
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#2
|
||||
if ((x!==0)&(y!==2)) {
|
||||
$ERROR('#2: Check Postfix Increment Operator for automatic semicolon insertion');
|
||||
throw new Test262Error('#2: Check Postfix Increment Operator for automatic semicolon insertion');
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
|
@ -18,7 +18,7 @@ y
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#1
|
||||
if ((x!==0)&(y!==1)) {
|
||||
$ERROR('#1: Check Postfix Increment Operator for automatic semicolon insertion');
|
||||
throw new Test262Error('#1: Check Postfix Increment Operator for automatic semicolon insertion');
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
@ -29,7 +29,7 @@ x
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#2
|
||||
if ((x!==0)&(y!==0)) {
|
||||
$ERROR('#2: Check Postfix Increment Operator for automatic semicolon insertion');
|
||||
throw new Test262Error('#2: Check Postfix Increment Operator for automatic semicolon insertion');
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
|
@ -19,7 +19,7 @@ y
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#1
|
||||
if ((z!==1)&&(y!==1)&&(x!==0)) {
|
||||
$ERROR('#1: ');
|
||||
throw new Test262Error('#1: ');
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
@ -32,7 +32,7 @@ y
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#2
|
||||
if ((z!==2)&&(y!==2)&&(x!==0)) {
|
||||
$ERROR('');
|
||||
throw new Test262Error('');
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
@ -45,7 +45,7 @@ y
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#3
|
||||
if ((z!==3)&&(y!==3)&&(x!==0)) {
|
||||
$ERROR('');
|
||||
throw new Test262Error('');
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
|
@ -22,7 +22,7 @@ y
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#1
|
||||
if ((z!==2)&&(y!==1)&&(x!==1)) {
|
||||
$ERROR('#1: ');
|
||||
throw new Test262Error('#1: ');
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
@ -33,7 +33,7 @@ x + + + y
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#2
|
||||
if ((z!==2)&&(y!==1)&&(x!==1)) {
|
||||
$ERROR('');
|
||||
throw new Test262Error('');
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
@ -47,7 +47,7 @@ y
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
//CHECK#3
|
||||
if ((z!==2)&&(y!==1)&&(x!==1)) {
|
||||
$ERROR('');
|
||||
throw new Test262Error('');
|
||||
}
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
|
Loading…
x
Reference in New Issue
Block a user