avoid extends error in test cases

This commit is contained in:
alexlamsl 2022-05-16 03:27:14 +08:00
parent e31bbe329a
commit 9ad4dde871

View File

@ -1805,7 +1805,7 @@ function createClassLiteral(recurmax, stmtDepth, canThrow, name) {
if (canThrow && rng(20) == 0) {
s += p;
} else {
s += "(" + p + " && " + p + ".constructor === Function ? " + p + " : function() {})";
s += "(typeof " + p + ' == "function" && typeof ' + p + '.prototype == "object" ? ' + p + " : function() {})";
}
}
s += " {\n";