chore(benchmark): add `{ __proto: null }` case
So I am just tired of @magic-akari and @mmis1000 and @jack-works asking me why not `{ __proto: null }`, so I updated the benchmark in the PR.
I have enabled `Allow edits by maintainers` so you can update the `README.md` file in my branch before merging this.
Also here is my run:
```
NullProtoObj via constructor x 207,586,282 ops/sec ±4.80% (81 runs sampled)
Object.create(null) x 54,415,324 ops/sec ±2.01% (89 runs sampled)
{} (normal object) x 194,340,713 ops/sec ±5.15% (77 runs sampled)
{__proto__:null} x 39,313,923 ops/sec ±2.37% (92 runs sampled)
Fastest is NullProtoObj via constructor
```
`{ __proto: null }` is even 40% slower than `Object.create(null)`.
合并状态:已合并 合并于 2025-05-21 关闭于 2025-05-21 0 条评论