mirror of https://github.com/tc39/test262.git
chore: migrate $ERROR -> throw new Test262Error in test/annexB/*
This commit is contained in:
parent
6e2a29417a
commit
d7f5a4e65c
|
@ -34,21 +34,21 @@ for (let letter of invalidControls()) {
|
||||||
var str = String.fromCharCode(char % 32);
|
var str = String.fromCharCode(char % 32);
|
||||||
var arr = re.exec(str);
|
var arr = re.exec(str);
|
||||||
if (str !== letter && arr !== null) {
|
if (str !== letter && arr !== null) {
|
||||||
$ERROR(`Character ${letter} unreasonably wrapped around as a control character`);
|
throw new Test262Error(`Character ${letter} unreasonably wrapped around as a control character`);
|
||||||
}
|
}
|
||||||
|
|
||||||
arr = re.exec(letter);
|
arr = re.exec(letter);
|
||||||
if (arr === null) {
|
if (arr === null) {
|
||||||
$ERROR(`Character ${letter} missing from character class ${source}`);
|
throw new Test262Error(`Character ${letter} missing from character class ${source}`);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
arr = re.exec("\\")
|
arr = re.exec("\\")
|
||||||
if (arr === null) {
|
if (arr === null) {
|
||||||
$ERROR(`Character \\ missing from character class ${source}`);
|
throw new Test262Error(`Character \\ missing from character class ${source}`);
|
||||||
}
|
}
|
||||||
arr = re.exec("c")
|
arr = re.exec("c")
|
||||||
if (arr === null) {
|
if (arr === null) {
|
||||||
$ERROR(`Character c missing from character class ${source}`);
|
throw new Test262Error(`Character c missing from character class ${source}`);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue