From 36d22d82aa202bb199967e9512281e9a53db42c9 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 21:33:14 +0200 Subject: Adding upstream version 115.7.0esr. Signed-off-by: Daniel Baumann --- .../object-literal-accessor-property-name.js | 29 ++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 js/src/tests/non262/expressions/object-literal-accessor-property-name.js (limited to 'js/src/tests/non262/expressions/object-literal-accessor-property-name.js') diff --git a/js/src/tests/non262/expressions/object-literal-accessor-property-name.js b/js/src/tests/non262/expressions/object-literal-accessor-property-name.js new file mode 100644 index 0000000000..11a7f20e04 --- /dev/null +++ b/js/src/tests/non262/expressions/object-literal-accessor-property-name.js @@ -0,0 +1,29 @@ +// Any copyright is dedicated to the Public Domain. +// http://creativecommons.org/licenses/publicdomain/ + +var gTestfile = 'object-literal-accessor-property-name.js'; +//----------------------------------------------------------------------------- +var BUGNUMBER = 715682; +var summary = + "Permit numbers and strings containing numbers as accessor property names"; +print(BUGNUMBER + ": " + summary); + +//----------------------------------------------------------------------------- + +({ get "0"() { } }); +({ get 0() { } }); +({ get 0.0() { } }); +({ get 0.() { } }); +({ get 1.() { } }); +({ get 5.2322341234123() { } }); + +({ set "0"(q) { } }); +({ set 0(q) { } }); +({ set 0.0(q) { } }); +({ set 0.(q) { } }); +({ set 1.(q) { } }); +({ set 5.2322341234123(q) { } }); + +//----------------------------------------------------------------------------- + +reportCompare(true, true); -- cgit v1.2.3