... | @@ -285,24 +285,31 @@ Of course, it is fine to use a qualified name in a record update. |
... | @@ -285,24 +285,31 @@ Of course, it is fine to use a qualified name in a record update. |
|
|
|
|
|
I've implemented the first option, adding a new warning `-fwarn-qualified-overloaded-record-fields` which is on by default.
|
|
I've implemented the first option, adding a new warning `-fwarn-qualified-overloaded-record-fields` which is on by default.
|
|
|
|
|
|
|
|
## Mangling selector names
|
|
|
|
|
|
|
|
|
|
|
|
We could mangle selector names (using `$sel_foo_T` instead of `foo`) even when the extension is disabled, but we decided not to because the selectors really should be in scope with their original names, and doing otherwise leads to:
|
|
|
|
|
|
|
|
- Trouble with import/export
|
|
|
|
- Trouble with deriving instances in GHC.Generics (makes up un-renamed syntax using field `RdrName`s)
|
|
|
|
- Boot files that export record selectors not working
|
|
|
|
|
|
## Outstanding bugs
|
|
## Outstanding bugs
|
|
|
|
|
|
- typechecker/should_fail/tcfail102 (changed error message)
|
|
- typechecker/should_fail/tcfail102 (changed error message)
|
|
|
|
|
|
## To do
|
|
## To do
|
|
|
|
|
|
- It'd be possible for associated types to have type parameters that are an \*instance of\* the class header. Feature request!
|
|
|
|
- With fundep in class, we don't need it in the instance.
|
|
- With fundep in class, we don't need it in the instance.
|
|
- Always mangle selector names (for simplicity)?
|
|
- Minimise contents of `AvailInfo` (to a list of `AvailFields Name`, where `data AvailFields name = NonOverloaded [name] | Overloaded [OccName]`). Use `lookupOrig` to lookup cached mangled names for selectors and pieces (get a `Module` from the `TyCon``Name`).
|
|
|
|
- When there is only one thing in scope, don't do make it polymorphic (but document trade-offs).
|
|
- Trouble with import/export
|
|
- Forbid ambiguous qualified overloaded fields.
|
|
- Trouble with deriving instances in GHC.Generics (makes up un-renamed syntax using field `RdrName`s)
|
|
- Add `HsVarOut RdrName id` instead of `HsSingleRecFld` (or perhaps rename `HsVar` to `HsVarIn`); also useful to recall how the user referred to something.
|
|
- Sort out impedance mismatch with boot files
|
|
- Could resolve Has constraints in the solver, like newtype coercions and SingI, rather than the instance malarkey.
|
|
- Minimise contents of `AvailInfo` (preferably just a list of field `OccName`s): use `newGlobalBinder` to lookup cached mangled names for selectors and pieces
|
|
|
|
|
|
|
|
- Sort out reporting of unused imports.
|
|
- Sort out reporting of unused imports.
|
|
- Make instances available to GHCi.
|
|
- Make instances available to GHCi.
|
|
- Fix Haddock.
|
|
- Haddock prints selector names in index and LaTeX exports list
|
|
|
|
|
|
- Consider syntactic sugar for `Upd` constraints.
|
|
- Consider syntactic sugar for `Upd` constraints.
|
|
- Improve unsolved `Accessor p f` error message where `p` is something silly?
|
|
- Improve unsolved `Accessor p f` error message where `p` is something silly?
|
... | | ... | |