Changes between Version 136 and Version 137 of TypeFunctionsStatus
- Jan 10, 2007 8:11:32 PM (8 years ago)
v136 v137 46 46 * `boxy_match`: Not sure yet. Do we have to handle the case where `t_ty` is a synonym family application? On the other hand, this prematching seems to be an approximation. How much does it hurt if we just ignore this? 47 47 * `boxy_lub`: Unclear. Also seems to approximate. 48 * `tcSubExp`: Probably need a case similar to the case marked ''(rule F2)''. This function already returns a coercion, so hopefully it is easy to extend that without changing the interface. 48 * `tcSubExp`: . 49 49 * `uTysOuter`, `u_tys`, `uPred`, `uVar`, and their intefaces `boxyUnify`, `boxyUnifyList`, `unifyType`, `unifyPred`, `unifyTheta`, and `unifyTypeList`: Generate wanted equalities and produce coercion(s). !!!Still need to check usage patterns!!! 50 50 To make things easy, we might want to always return a `HsWrapper` value (unless the unification fails), which is `WpHole` whenever the coercion is empty. The disadvantage is that this blows the tree between type checking and desugaring up. An alternative is to return the coercion only when needed, but write some auxilliary functions that take the result of `boxySplitTyConApp` and friends and turn the optional coercion result in an always present (real Haskell) function that we always apply to the type-checked pattern (in `TcPat`) or expression. It is simply `id` when we don't need a coercion. 51 52 53 54 51 55 2. Type checking in the presence of associated synonym defaults. (Default AT synonyms are only allowed for ATs defined in the same class.) 52 56 3. Type check functional dependencies as type functions.