Skip to content

Don't report used duplicate record fields as unused

sheaf requested to merge sheaf/ghc:T24035 into master

Ticket: #24035 (closed)

This MR fixes the bug reported in #24035 (closed) in which the import of a duplicate record field could be erroneously reported as unused.

The issue is that an import of the form import M (fld) can import several different Names, and we should only report an error if ALL of those Names are unused, not if ANY are.

Note [Reporting unused imported duplicate record fields] in GHC.Rename.Names explains the solution to this problem.

Merge request reports

Loading