Rename LenientThis to LegacyLenientThis.
This CL renames Web IDL |LenientThis| to |LegacyLenientThis| to make its
usage more clear.
Bug: 1072773
Change-Id: I2f4ad082cad0b2598dcf36cd50247923b40a0ca9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2371146
Reviewed-by: Yuki Shiino <yukishiino@chromium.org>
Reviewed-by: Kent Tamura <tkent@chromium.org>
Commit-Queue: Zhuoyu Qian <zhuoyu.qian@samsung.com>
Cr-Commit-Position: refs/heads/master@{#803018}
diff --git a/WebIDL/ecmascript-binding/es-exceptions/DOMException-custom-bindings.any.js b/WebIDL/ecmascript-binding/es-exceptions/DOMException-custom-bindings.any.js
index ed05d27..cd4e5b6 100644
--- a/WebIDL/ecmascript-binding/es-exceptions/DOMException-custom-bindings.any.js
+++ b/WebIDL/ecmascript-binding/es-exceptions/DOMException-custom-bindings.any.js
@@ -27,7 +27,7 @@
const getter = Object.getOwnPropertyDescriptor(DOMException.prototype, "message").get;
assert_throws_js(TypeError, () => getter.apply({}));
-}, "message getter performs brand checks (i.e. is not [LenientThis]");
+}, "message getter performs brand checks (i.e. is not [LegacyLenientThis])");
test(() => {
const e = new DOMException("message", "name");
@@ -44,7 +44,7 @@
const getter = Object.getOwnPropertyDescriptor(DOMException.prototype, "name").get;
assert_throws_js(TypeError, () => getter.apply({}));
-}, "name getter performs brand checks (i.e. is not [LenientThis]");
+}, "name getter performs brand checks (i.e. is not [LegacyLenientThis])");
test(() => {
const e = new DOMException("message", "name");
@@ -61,7 +61,7 @@
const getter = Object.getOwnPropertyDescriptor(DOMException.prototype, "code").get;
assert_throws_js(TypeError, () => getter.apply({}));
-}, "code getter performs brand checks (i.e. is not [LenientThis]");
+}, "code getter performs brand checks (i.e. is not [LegacyLenientThis])");
test(() => {
const e = new DOMException("message", "InvalidCharacterError");
diff --git a/html/browsers/origin/cross-origin-objects/cross-origin-objects.html b/html/browsers/origin/cross-origin-objects/cross-origin-objects.html
index 1d45606..3b7c783 100644
--- a/html/browsers/origin/cross-origin-objects/cross-origin-objects.html
+++ b/html/browsers/origin/cross-origin-objects/cross-origin-objects.html
@@ -656,7 +656,7 @@
var desc = Object.getOwnPropertyDescriptor(window, "onmouseenter");
var f = () => {};
- // Check that it has [LenientThis] behavior
+ // Check that it has [LegacyLenientThis] behavior
assert_equals(desc.get.call({}), undefined, "getter should return undefined");
desc.set.call({}, f); // Should not throw.
@@ -669,14 +669,14 @@
assert_equals(desc.get.call(B), null, "Should have been reset");
// Check that applying it to a cross-origin window throws instead of doing
- // the [LenientThis] behavior.
+ // the [LegacyLenientThis] behavior.
assert_throws_dom("SecurityError", () => {
desc.get.call(win);
}, "Should throw when getting cross-origin");
assert_throws_dom("SecurityError", () => {
desc.set.call(win, f);
}, "Should throw when setting cross-origin");
-}, "LenientThis behavior");
+}, "LegacyLenientThis behavior");
// We do a fresh load of the subframes for each test to minimize side-effects.
// It would be nice to reload ourselves as well, but we can't do that without