[GHC] #13545: Remove duplication between lookupSubBndrOcc and lookupExportChild

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild -------------------------------------+------------------------------------- Reporter: mpickering | Owner: (none) Type: task | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.0.1 Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: None/Unknown Unknown/Multiple | Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- `lookupSubBndrOcc` is used in expressions such as `x { y = 5 }` to resolve field labels such as `y`. `lookupExportChild` is used in export lists such as `T(A, x)` to lookup `A` and `x`. They contain very similar logic but it is duplicated in two places which caused #13528. It should be easy to refactor them them to deduplicate the logic. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13545 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild -------------------------------------+------------------------------------- Reporter: mpickering | Owner: (none) Type: task | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by simonpj): Sounds plausible.. are you volunteering Matthew? -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13545#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild -------------------------------------+------------------------------------- Reporter: mpickering | Owner: mpickering Type: task | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by mpickering): * owner: (none) => mpickering Comment: Yes, and other refactorings around RnEnv. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13545#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild
-------------------------------------+-------------------------------------
Reporter: mpickering | Owner: mpickering
Type: task | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 8.0.1
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by Ben Gamari

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild -------------------------------------+------------------------------------- Reporter: mpickering | Owner: mpickering Type: task | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.0.1 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by bgamari): * status: new => closed * resolution: => fixed * milestone: => 8.4.1 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13545#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild -------------------------------------+------------------------------------- Reporter: mpickering | Owner: (none) Type: task | Status: new Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by simonpj): * owner: mpickering => (none) * status: closed => new * resolution: fixed => Comment: The commit in comment:3 does not close this ticket. On the contrary, it was the reason for opening it. No? -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13545#comment:5 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild -------------------------------------+------------------------------------- Reporter: mpickering | Owner: (none) Type: task | Status: new Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by bgamari): Oh dear, yes, I misread. Apologies. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13545#comment:6 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild -------------------------------------+------------------------------------- Reporter: mpickering | Owner: mpickering Type: task | Status: new Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by mpickering): * owner: (none) => mpickering -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13545#comment:7 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild -------------------------------------+------------------------------------- Reporter: mpickering | Owner: mpickering Type: task | Status: new Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.0.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by mpickering): There is the slight complication that `lookupExportChild` runs after typechecking which means that it invokes typechecker lookup functions to resolve things to do with record pattern synonym selectors. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13545#comment:8 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild
-------------------------------------+-------------------------------------
Reporter: mpickering | Owner: mpickering
Type: task | Status: new
Priority: normal | Milestone: 8.4.1
Component: Compiler | Version: 8.0.1
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by Matthew Pickering

#13545: Remove duplication between lookupSubBndrOcc and lookupExportChild -------------------------------------+------------------------------------- Reporter: mpickering | Owner: mpickering Type: task | Status: closed Priority: normal | Milestone: 8.4.1 Component: Compiler | Version: 8.0.1 Resolution: fixed | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by mpickering): * status: new => closed * resolution: => fixed -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/13545#comment:10 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC