HORIZON HASKELLDocslts/ghc-9.10.xc74966e2026-09-27Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · c74966e · 2026-09-27

Moduleghc-9.10.3GHC2021

GHC.StgToJS.Linker.Linker

GHCJS linker, collects dependencies from the object files which contain linkable units with dependency information

  • 3 types
  • 11 values
  • Packageghc-9.10.3
  • Exports14
  • LanguageGHC2021
  • LicenceBSD-3-Clause
  • SourceLinker.hs

Embed a JS file into a JS object .o file

JS files may contain option pragmas of the form: //#OPTIONS: One of those is //#OPTIONS:CPP. When it is set, we append some common CPP definitions to the file and call cpp on it.

Other options (e.g. EMCC additional flags for link time) are stored in the JS object header. See JSOptions.

Given a base link plan (assumed to be already linked) and a new link plan, compute `(diff, total)` link plans.

  • diff is the incremental link plan to get from base to total

  • total is the total link plan as if base and new were linked at once