Changes between Version 80 and Version 81 of ExplicitCallStack
- Timestamp:
- 01/25/12 22:23:17 (16 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
ExplicitCallStack
v80 v81 26 26 This doesn't quite work today because `loc` has type `Language.Haskell.TH.Syntax.Loc`, a record of location information, and that isn't an instance of `Lift` (yet). But the idea is basically fine: TH gives you access to the current source location. 27 27 28 2. But that doesn't help with 'head'. We want to pass head's ''call site'' to head. That's what jhc does when you give 'head' the a magic [http://repetae.net/ john/computer/jhc/jhc.html SRCLOC_ANNOTATE pragma]:28 2. But that doesn't help with 'head'. We want to pass head's ''call site'' to head. That's what jhc does when you give 'head' the a magic [http://repetae.net/computer/jhc/jhc.shtml SRCLOC_ANNOTATE pragma]: 29 29 * every call to `head` gets replaced with `head_check $currentLocation` 30 30 * in jhc, you get to write `head_check` yourself, with type
