[GHC] #9049: Expose srcLoc from the assertion architecture to allow better error messages
GHC
ghc-devs at haskell.org
Mon Jan 5 14:17:30 UTC 2015
#9049: Expose srcLoc from the assertion architecture to allow better error
messages
-------------------------------------+-------------------------------------
Reporter: nh2 | Owner: gridaphobe
Type: feature request | Status: patch
Priority: normal | Milestone: 7.12.1
Component: Compiler | Version: 7.8.2
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
Type of failure: None/Unknown | Unknown/Multiple
Blocked By: | Test Case:
Related Tickets: | Blocking:
| Differential Revisions: Phab:D578
-------------------------------------+-------------------------------------
Comment (by simonpj):
Re "the second bullet point under Implementation Details", I now
understand. Good point. The issue is this:
{{{
f :: (?loc :: CallStack) => IO ()
f = print (?location :: CallStack)
}}}
There are two alternatives for what to pass to `print`:
* Pass the call site of `print`, pushed onto the passed-in call stack
* Pass a singleton stack, just the call site of `print`, reflecting the
change in name.
You have implemented the first, but I think the latter would perhaps be
more intuitive. Does anyone else have opinions?
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9049#comment:26>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list