can't deal with priority correctlly
tjx666 opened this issue · comments
余腾靖 commented
package.json:
{
"name": "commonjs",
"exports": {
"./a/b/*": "./dist/hello.js",
"./a/*/c": null
}
}
output:
thread '' panicked at 'internal error: entered unreachable code', /Users/runner/.cargo/registry/src/github.com-1ecc6299db9ec823/nodejs-resolver-0.0.34/src/map.rs:135:18
note: run withRUST_BACKTRACE=1
environment variable to display a backtrace
fatal runtime error: failed to initiate panic, error 5
[1] 8437 abort node apps/commonjs-app/index.js
enhanced-resolve used by webpack works:
bohan commented
Thanks for your feedback, probably because I forgot to handle null
https://github.com/web-infra-dev/nodejs_resolver/blob/main/src/map.rs#L118
btw, node binding is using a lower version and may have many bugs that have been fixed