#version: dbae081(https://github.com/WebKit/WebKit-http/commit/dbae081ad7e22d9ab61edf2f337f6c2bb593c7f8) #Testcase: a = { get p() {print('get');}, p: 2, set p(b) {print('set');} }; a.p = 0; print('a.p:', a.p); #Command: ./webkit/WebKitBuild/Release/bin/jsc testcase.js #Output: a.p: 0 #Expected output: set a.p: undefined #Description: When executing this test case, other engines (such as v8, SpiderMonkey, chakra, etc.) seem to call the 'get' method defined in the 'a' object and output the value of 'a.p' as 'undefined', but JavascriptCore changed the value of 'a.p' to 0. Maybe this is a bug of JavascriptCore.
(In reply to NWU_NISL from comment #0) > #version: > dbae081(https://github.com/WebKit/WebKit-http/commit/ > dbae081ad7e22d9ab61edf2f337f6c2bb593c7f8) > > #Testcase: > a = { > get p() {print('get');}, > p: 2, > set p(b) {print('set');} > }; > > a.p = 0; > print('a.p:', a.p); > > #Command: > ./webkit/WebKitBuild/Release/bin/jsc testcase.js > > #Output: > a.p: 0 > > #Expected output: > set > a.p: undefined > > #Description: > When executing this test case, other engines (such as v8, SpiderMonkey, > chakra, etc.) seem to call the 'get' method defined in the 'a' object and > output the value of 'a.p' as 'undefined', but JavascriptCore changed the > value of 'a.p' to 0. Maybe this is a bug of JavascriptCore.
The test case in the description I found has some errors, I have modified it in the comments, please check it out.
<rdar://problem/73382771>
Created attachment 451017 [details] Patch
Created attachment 451019 [details] Patch Adjust LayoutTests/js/class-syntax-method-names.html to pass on V8 / SM.
Comment on attachment 451019 [details] Patch r=me
Comment on attachment 451019 [details] Patch (In reply to Yusuke Suzuki from comment #6) > Comment on attachment 451019 [details] > Patch > > r=me Thanks Yusuke! (In reply to NWU_NISL from comment #2) > The test case in the description I found has some errors, I have modified it > in the comments, please check it out. We very much appreciate you reporting all the bugs. You've caught some cases that our coverage, fuzzers, and test262 all missed. Please keep them coming!
Committed r289166 (246862@main): <https://commits.webkit.org/246862@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 451019 [details].