(7.x backport) NODE_OPTIONS, and one of its dependant refactors
requested to merge github/fork/sam-github/backport-12241-use-vector-for-preload-modules into v7.x-staging
Backport of https://github.com/nodejs/node/pull/12241 to 7.x
Also rolled in https://github.com/nodejs/node/pull/12648, because it depends on the use of std::vector.
A dynamically allocated array was being used, simplify the memory management by using std::vector.
PR-URL: https://github.com/nodejs/node/pull/12241 Reviewed-By: Richard Lau riclau@uk.ibm.com Reviewed-By: James M Snell jasnell@gmail.com Reviewed-By: Daniel Bevenius daniel.bevenius@gmail.com Reviewed-By: Colin Ihrig cjihrig@gmail.com Reviewed-By: Anna Henningsen anna@addaleax.net
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
documentation is changed or added -
commit message follows commit guidelines