Reject all duplicate declarations involving DuplicateRecordFields (fixes #17965)
This fixes a bug that resulted in some programs being accepted that used the same identifier as a field label and another declaration, depending on the order they appeared in the source code.
Showing
- compiler/GHC/Rename/Names.hs 7 additions, 5 deletionscompiler/GHC/Rename/Names.hs
- compiler/GHC/Types/Name/Reader.hs 7 additions, 1 deletioncompiler/GHC/Types/Name/Reader.hs
- testsuite/tests/overloadedrecflds/should_fail/T17965.hs 4 additions, 0 deletionstestsuite/tests/overloadedrecflds/should_fail/T17965.hs
- testsuite/tests/overloadedrecflds/should_fail/T17965.stderr 5 additions, 0 deletionstestsuite/tests/overloadedrecflds/should_fail/T17965.stderr
- testsuite/tests/overloadedrecflds/should_fail/all.T 1 addition, 0 deletionstestsuite/tests/overloadedrecflds/should_fail/all.T
Loading
Please register or sign in to comment