Unverified Commit 150b8f7f authored by Anna Henningsen's avatar Anna Henningsen
Browse files

src: minor c++ refactors to module_wrap

- Move `module_map` to `Environment` instead of having it be global
  state
- `std::map` → `std::unordered_map`
- Remove one level of indirection for the map values
- Clean up empty vectors in `module_map`
- Call `Reset()` on all persistent handles in `resolve_cache_`
- Add a missing `HandleScope` to `ModuleWrap::~ModuleWrap()`

PR-URL: https://github.com/nodejs/node/pull/15515


Reviewed-By: default avatarJames M Snell <jasnell@gmail.com>
Reviewed-By: default avatarBradley Farias <bradley.meck@gmail.com>
Reviewed-By: default avatarTimothy Gu <timothygu99@gmail.com>
parent b605b153
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment