prepack icon indicating copy to clipboard operation
prepack copied to clipboard

Revisit "widened property" mechanism

Open sebmarkbage opened this issue 6 years ago • 1 comments

I find the mechanism to define a widened property as a value a bit awkward. It has many special cases.

It leads to some tricky serialization issues when we try to special case its initialization by emitting assignments and ensuring that we omit the properties from the first initialization. It is at least suboptimal but also possibly technically incorrect in some cases since we have to be careful with using assignment instead of defineProperty.

I've found several bugs related to "widened property" already:

#1551 #1565 #1567

I wonder if we should revisit this design. It seems to me that maybe the value itself isn't what needs special casing but the property itself?

sebmarkbage avatar Mar 12 '18 01:03 sebmarkbage

Found another one: #1574

sebmarkbage avatar Mar 12 '18 20:03 sebmarkbage