You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm going through the tutorial module, and there's somewhat heavy usage of OverloadedLabels in the code that makes compiles really slow for me (similar to the case with gi-gtk). Is there an alternative (I'm willing to endure some boilerplate/prefixed record selector names/etc.) to this?
Using generic-lens might be an option: it supports things like label @"foo" using nothing but GHC.Generics, which greatly cuts down on the compile-time overhead without sacrificing any type safety. However, from my limited experience with tisch, I'm not sure how the type/data family techniques used here will interact with generic programming. (What would you even derive Generic for?)
Edit: I've found the IsLabel instances (!) which showed me what I wanted to be doing instead (in this case, something like view (col (Proxy @Foo))). Even then, I'm interested in whether there's a lower-friction API possible using generics.
The text was updated successfully, but these errors were encountered:
On Jun 17, 2017 5:10 PM, "Soham Chowdhury" ***@***.***> wrote:
I'm going through the tutorial module, and there's somewhat heavy usage of
OverloadedLabels in the code that makes compiles really slow. Is there an
alternative (I'm willing to endure some boilerplate/prefixed record
selector names/etc.) to this?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#29>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAAM5m8yhvhmnZQqVFhUeDy_2AQsy3VTks5sE-xKgaJpZM4N9P8q>
.
I'm going through the tutorial module, and there's somewhat heavy usage of
OverloadedLabels
in the code that makes compiles really slow for me (similar to the case withgi-gtk
). Is there an alternative (I'm willing to endure some boilerplate/prefixed record selector names/etc.) to this?Using
generic-lens
might be an option: it supports things likelabel @"foo"
using nothing but GHC.Generics, which greatly cuts down on the compile-time overhead without sacrificing any type safety. However, from my limited experience withtisch
, I'm not sure how the type/data family techniques used here will interact with generic programming. (What would you even deriveGeneric
for?)Edit: I've found the
IsLabel
instances (!) which showed me what I wanted to be doing instead (in this case, something likeview (col (Proxy @Foo))
). Even then, I'm interested in whether there's a lower-friction API possible using generics.The text was updated successfully, but these errors were encountered: