Closed
Bug 1160713
Opened 10 years ago
Closed 10 years ago
Proxy triggers indirect traps incorrectly
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
INVALID
People
(Reporter: getify, Unassigned)
Details
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:40.0) Gecko/20100101 Firefox/40.0
Build ID: 20150427030207
Steps to reproduce:
var handlers = {
getOwnPropertyDescriptor(target,prop) {
console.log(
"getOwnPropertyDescriptor"
);
return Object.getOwnPropertyDescriptor(
target, prop
);
},
defineProperty(target,prop,desc){
console.log( "defineProperty" );
return Object.defineProperty(
target, prop, desc
);
}
},
proxy = new Proxy( {}, handlers );
proxy.a = 2;
// getOwnPropertyDescriptor
// defineProperty
Expected results:
According to 9.5.9, the default `[[Set]]` handler should not be firing `[[GetOwnProperty]]` or `[[DefineOwnProperty]]` traps on the proxy object (all actions should be against the target)
Reporter | ||
Updated•10 years ago
|
OS: Unspecified → All
Hardware: Unspecified → All
Reporter | ||
Comment 1•10 years ago
|
||
Closing my own bug. Sorry for false alarm.
For posterity sake, 9.5.9 does indeed say target[[Set]], but in 9.1.9, it says receiver[[GetOwnProperty]], etc.
Status: UNCONFIRMED → RESOLVED
Closed: 10 years ago
Resolution: --- → INVALID
You need to log in
before you can comment on or make changes to this bug.
Description
•