Arrow Functions
What is the behavior of `new.target` in arrow functions?
The `new.target` property in arrow functions is inherited from the enclosing function. Arrow functions don't have their own `new.target` binding, just as they don't have their own `this`, `arguments`, or `super` bindings. If an arrow function is defined within a function that was called with `new`, it inherits the `new.target` value from that enclosing function, which would be a reference to the constructor that was invoked with `new`. If the arrow function is not inside any function that was called with `new`, accessing `new.target` will behave according to the normal rules: it will be `undefined` in regular function calls or reference the appropriate constructor in constructor calls. It's also worth noting that since arrow functions cannot be used as constructors (cannot be called with the `new` operator), `new.target` inside an arrow function will never refer to the arrow function itself. This behavior is consistent with how arrow functions handle other function-specific properties by lexically inheriting them.