Closed kim closed 5 years ago
this pattern is factorable out into an abstraction
I guess we could wrap it in a newtype to hide the RankNTypes
. Perhaps worth trying in the oscoin
codebase, as passing a partially applied Telemetry.emit
unifying the argument increases modularity in a few places.
Right, the above (newtype with a tucked forall
in these) was basically what I had in mind 😉
I can see how we might want this desirable property of precise callstack traces in a lot of places, so perhaps having something like a Traced
newtype we somehow apply to have this precision might be worth a try.
Perhaps worth trying in the oscoin codebase, as passing a partially applied Telemetry.emit unifying the argument increases modularity in a few places.
Indeed. There are a bunch of places in oscoin
where I do recall we weren't getting exactly precise callstacks, and would be interesting to see how that changes.
This allows to get at the
SrcLoc
of the actual callsite, not the interpreter's.