You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[js-compiler] Remove special handling for JS library aliases. NFC (#25441)
This change remove some special casing in `addFromLibrary` which
simplifies the code, and also lays the groundwork for #25441 which
explicitly allows JS symbol to alias native ones.
This special handling was added in #19046 in order to deal with case
where `glXXX` symbols were simultaneously aliased by `emscripten_glXX`
and exported (in the case of MAIN_MODULE=1).
However, this work is no longer needed since in #21785 we stopped
stopped included symbol exported due to `MAIN_MODULE=1` as part of
`WASM_EXPORTS` (the symbols are only exported to side modules, not to
JS).
In original problem was that `emscripten_glXX` should always points to
the original JS implementation, even if a native version is exported.
Just in case somebody is explicitly exporting these symbols this change
also flips the aliases such that the `glXX` functions are now aliases of
`emscripten_glXX` and not the other way around. This means that
exporting `glXXX` will replace/override the alias, but will not effect
`emscripten_glXX`.
0 commit comments