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.Iface.Tidy

Tidying up Core

This module's purpose is to prepare the Core program for two distinct purposes: * To be serialised into the module's interface file * To feed to the code generator

The most important tasks are: * Determine which Names should ultimately be Internal and External (which may differ to whether they were originally Internal or External). See `Note [About the NameSorts]` in GHC.Types.Name. For example, in: module M where f x = x + y where y = factorial 4 could be optimized during the Core pass to: module M where y = factorial 4 f x = x + y in which case y would be changed from Internal to External.

  • Rename local identifiers to avoid name clashes, so that unfoldings etc can be serialialised using the OccName, without Uniques.

For example (x_5 means x with a Unique of `5`): f x_12 x_23 = x_12 would be changed to: f x_12 x1_23 = x_12

  • 2 types
  • 2 values
  • Packageghc-9.10.3
  • Exports4
  • LanguageGHC2021
  • LicenceBSD-3-Clause
  • SourceTidy.hs
datadata TidyOpts
#

Constructors