diff options
author | Ryan Scott <ryan.gl.scott@gmail.com> | 2023-05-01 20:03:39 -0400 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2023-05-04 15:02:02 -0400 |
commit | e8b72ff6e4aee1f889a9168df57bb1b00168fd21 (patch) | |
tree | a2692a03953dbd1927c62ac0b213c8d5a445332e /compiler/GHC/Rename/Expr.hs | |
parent | b3226616beaa8cd4d3289b8a9d4bb0a9b8936f8e (diff) | |
download | haskell-e8b72ff6e4aee1f889a9168df57bb1b00168fd21.tar.gz |
Fix type variable substitution in gen_Newtype_fam_insts
Previously, `gen_Newtype_fam_insts` was substituting the type variable binders
of a type family instance using `substTyVars`, which failed to take type
variable dependencies into account. There is similar code in
`GHC.Tc.TyCl.Class.tcATDefault` that _does_ perform this substitution properly,
so this patch:
1. Factors out this code into a top-level `substATBndrs` function, and
2. Uses `substATBndrs` in `gen_Newtype_fam_insts`.
Fixes #23329.
Diffstat (limited to 'compiler/GHC/Rename/Expr.hs')
0 files changed, 0 insertions, 0 deletions