wasm-linker-js icon indicating copy to clipboard operation
wasm-linker-js copied to clipboard

Add option to error on import shadowing

Open radu-matei opened this issue 5 years ago • 0 comments

In the current implementation of the linker, when duplicate module names, or duplicate import items are defined, the last one defined always takes precedence - see behavior in the tests: https://github.com/deislabs/wasm-linker-js/blob/9c13ba33bd635fdf7fbe60ed14f22bb4a898edfc/tests/linker.ts#L21-L47

There should probably be a linker setting that controls whether an error should be thrown when trying to define an object that already exists in the imports cache.

radu-matei avatar Nov 12 '20 08:11 radu-matei