class C { static caller() { return 'abc'; } } C.caller(); // abc C.caller = function () { return 'cba'; }; C.caller(); // cab C.arguments = function () {} ??? // In Chrome && Firefox - TypeError
(In reply to GSkachkov from comment #0) > class C { > static caller() { return 'abc'; } > } r225845 fixed JSFunction::put() and JSFunction::defineOwnProperty() to perform ordinary [[Set]] / [[DefineOwnProperty]] for classes and strict functions. I am adding this test case as part of https://bugs.webkit.org/show_bug.cgi?id=225277. > C.arguments = function () {} ??? // In Chrome && Firefox - TypeError This throws TypeError because of https://tc39.es/ecma262/#sec-addrestrictedfunctionproperties. *** This bug has been marked as a duplicate of bug 163579 ***