On Sat, Dec 13, 2014 at 5:16 PM, Erik Arvidsson <[email protected]> wrote:
> Regarding extra tests.
>
> How about an object that has getters for all the flags and then assert that
> these are called in the right order?
Sounds good.
> Also, do the same thing with the
> getters returning objects with valueOf to ensure that the valueOf is called
> before the next getter is invoked.
Do you mean this scenario?
Object.getOwnPropertyDescriptor(RegExp.prototype, 'flags').get.call({
get global() {
return {
valueOf: function() {
return false;
}
};
}
});
// returns 'g' per spec, AFAICT, not the empty string
I don’t see why `valueOf` would be called here. Did I misunderstand?
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups
"v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.