Closed Bug 1700958 Opened 5 years ago Closed 4 years ago

Clean up PropertyDescriptor

Categories

(Core :: JavaScript Engine, task, P3)

task

Tracking

()

RESOLVED FIXED

People

(Reporter: jandem, Unassigned)

References

Details

Bug 1470081 is cleaning up the getter/setter code in PropertyDescriptor, but there's more to do:

  • setGetter and setSetter probably shouldn't exist at all.
  • For the attributes it would also be nicer to have checked accessors instead of just exposing the underlying field directly.
  • There's an object field that's set for lookups, but this doesn't really belong in the property descriptor. It would be nicer to have a separate type that contains this object + a PropertyDescriptor.

Great! Sadly we use object() in a lot of places to check if the PropertyDescriptor is not undefined (in spec terms). Making this more explicit would be great. I might give that part a shot during the weekend.

Blocks: 1712764
Blocks: 1713083

I can't really think of any additional improvements. We are in a pretty good state now.

Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.