Sign in
webkit
/
WebKit
/
3f78a298b8cb2d7ccc1b4dafb89a4d60eb2fbe8f
/
.
/
JSTests
/
es6
/
function_name_property_symbol-keyed_methods.js
blob: e915dd9731e6a7f1aba6e8ec8ca4eabe8b642749 [
file
] [
log
] [
blame
]
function
test
()
{
var
sym1
=
Symbol
(
"foo"
);
var
sym2
=
Symbol
();
var
o
=
{
[
sym1
]:
function
(){},
[
sym2
]:
function
(){}
};
return
o
[
sym1
].
name
===
"[foo]"
&&
o
[
sym2
].
name
===
""
;
}
if
(!
test
())
throw
new
Error
(
"Test failed"
);