Commit 4fed62c8 authored by Evan Lucas's avatar Evan Lucas Committed by James M Snell
Browse files

module: cache regular expressions

None of these regular expressions will change, so there is no need to
generate them every time in hot code paths.

Provides a small performance improvement in module loading. (5-10%)

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


Reviewed-By: default avatarColin Ihrig <cjihrig@gmail.com>
Reviewed-By: default avatarJames M Snell <jasnell@gmail.com>
parent e3949b2c
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