
Simon Peyton Jones pushed to branch wip/T23162-spj at Glasgow Haskell Compiler / GHC Commits: 3a581928 by Simon Peyton Jones at 2025-09-28T22:48:04+01:00 Wibble Notes - - - - - 2 changed files: - compiler/GHC/Tc/Gen/App.hs - compiler/GHC/Tc/Utils/TcType.hs Changes: ===================================== compiler/GHC/Tc/Gen/App.hs ===================================== @@ -96,7 +96,7 @@ Some notes relative to the paper variables. We keep track of which variables are instantiation variables by giving them a TcLevel of QLInstVar, which is like "infinity". - See Note [QuickLook instantation varaibles] in GHC.Tc.Types.TcType. + See Note [QuickLook instantiation variables] in GHC.Tc.Types.TcType. (QL2) When we learn what an instantiation variable must be, we simply unify it with that type; this is done in qlUnify, which is the function mgu_ql(t1,t2) @@ -114,7 +114,7 @@ Some notes relative to the paper Note [Instantiation variables are short lived] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * An instantation variable is a mutable meta-type-variable, whose level number - is QLInstVar. See Note [QuickLook instantation varaibles] in GHC.Tc.Utils.TcType. + is QLInstVar. See Note [QuickLook instantiation variables] in GHC.Tc.Utils.TcType. * Ordinary unification variables always stand for monotypes; only instantiation variables can be unified with a polytype (by `qlUnify`). @@ -909,7 +909,7 @@ addArgCtxt ctxt (L arg_loc arg) thing_inside ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ During QuickLook, when we instantiate a function's type (specifically, in `tcInstFun`), we must instantiate it with so-called "instantiation variables". -See Note [QuickLook instantation variables] in GHC.Tc.Utils.TcType. +See Note [QuickLook instantiation variables] in GHC.Tc.Utils.TcType. So `tcInstFun` uses a family of specialised functions, defined below, like instantiateSigmaQL ===================================== compiler/GHC/Tc/Utils/TcType.hs ===================================== @@ -779,8 +779,8 @@ We arrange the TcLevels like this QLInstVar The level for QuickLook instantiation variables See Note [QuickLook instantiation variables] -Note [QuickLook instantation variables] -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Note [QuickLook instantiation variables] +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ A QuickLook instantiation variable is identified precisely by having a TcLevel of QLInstVar See (QL1) in Note [Quick Look overview] in GHC.Tc.Gen.App. View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/3a581928a2dc3b07160efc3c55ebd94d... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/3a581928a2dc3b07160efc3c55ebd94d... You're receiving this email because of your account on gitlab.haskell.org.