In ES6 this is done via @@create installing a list of [[InternalSlots]].
Discuss how brand checks should be kept to the minimum possible, e.g. promises only require the brand once (Promise.prototype.then) and use the brand to make a decision one other time (Promise.resolve).
This will require specs making their internal slots more explicit so they can be installed on arbitrary objects.
In ES6 this is done via @@create installing a list of [[InternalSlots]].
Discuss how brand checks should be kept to the minimum possible, e.g. promises only require the brand once (
Promise.prototype.then
) and use the brand to make a decision one other time (Promise.resolve
).This will require specs making their internal slots more explicit so they can be installed on arbitrary objects.