Use Object.defineProperty when available.