[GHC] #12617: Make the interface of traceTc and traceRn the same

#12617: Make the interface of traceTc and traceRn the same -------------------------------------+------------------------------------- Reporter: mpickering | Owner: Type: task | Status: new Priority: lowest | 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: -------------------------------------+------------------------------------- It always seemed strange to me that the interfaces for `traceTc` and `traceRn` were different. {{{#!hs traceTc :: String -> SDoc -> TcM () traceRn :: SDoc -> RnM () }}} I personally prefer using the `traceTc` interface and have to look up each time which function uses which interface. It seems beneficial but annoying to make `traceRn` have the same interface to improve usability slightly. Are there any objections if someone was to do this? -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12617 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12617: Make the interface of traceTc and traceRn the same -------------------------------------+------------------------------------- Reporter: mpickering | Owner: Type: task | Status: new Priority: lowest | 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): I'm all for it. Historical accident. I much prefer the `traceTc` interface. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12617#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12617: Make the interface of traceTc and traceRn the same -------------------------------------+------------------------------------- Reporter: mpickering | Owner: Type: task | Status: new Priority: lowest | 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 mpickering): Modifying the `traceRn` interface to the `traceTc` interface causes 3 of the performance tests to fail due to the strings being floated to the top level (by `-ffull-laziness`) and hence allocated. Previously these strings were not allocated as there is a rule which optimises `text "abc"` to `ptext (Ptr p)`. Here is the diff where I tried various things to fix this: https://phabricator.haskell.org/D2586 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12617#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12617: Make the interface of traceTc and traceRn the same -------------------------------------+------------------------------------- Reporter: mpickering | Owner: Type: task | Status: new Priority: lowest | 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 ezyang): Thanks for the diff. Surely whatever problem traceRn has, traceTc has too? Adding a rule for both cases seems useful. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12617#comment:3 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12617: Make the interface of traceTc and traceRn the same -------------------------------------+------------------------------------- Reporter: mpickering | Owner: Type: task | Status: new Priority: lowest | 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 mpickering): The rule doesn't seem to fix anything. I can't reproduce the failing tests on my machine which makes development slow. You are right though that there is also this problem with traceTc. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12617#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#12617: Make the interface of traceTc and traceRn the same
-------------------------------------+-------------------------------------
Reporter: mpickering | Owner:
Type: task | Status: new
Priority: lowest | 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

#12617: Make the interface of traceTc and traceRn the same -------------------------------------+------------------------------------- Reporter: mpickering | Owner: Type: task | Status: closed Priority: lowest | Milestone: 8.2.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.2.1 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12617#comment:6 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC