Skip to content

Substitute free variables captured by breakpoints in SpecConstr

Torsten Schmits requested to merge tweag/ghc:wip/torsten.schmits/23267 into master

Tracking ticket: #23267 (closed)

The variable substitution procedure in SpecConstr ignored the free variables in Breakpoint values, which caused them to refer to the Ids from the unspecialized expression.

The code I added is similar to what Specialise is doing.

Most of the other modules in GHC/Core/Opt put the Tickish back unmodified, but I don't know if any of those would need similar treatment.

Work sponsored by Tweag

Edited by Torsten Schmits

Merge request reports