From: Lady Date: Fri, 24 Nov 2023 16:37:08 +0000 (-0500) Subject: De‐classify property descriptors; move to value.js X-Git-Url: https://git.ladys.computer/Pisces/commitdiff_plain/50ab30fc3a257e46da6b8bdc0dad054f729e16e1?hp=50ab30fc3a257e46da6b8bdc0dad054f729e16e1 De‐classify property descriptors; move to value.js The conversion to and from property descriptors doesn’t only look at own properties, so it is convenient to create ones with a null prototype (to prevent attempts at hacking into, e·g, `Object.prototype`). This means the existing class‐based approach isn’t viable and a more functional approach is better. Many of the property descriptor functions explicitly handle undefined, so treating them as values and not objects makes sense, even if some (`completePropertyDescriptor`, `toPropertyDescriptor`) throw if their argument is not an object. ---