shapeless-guide
shapeless-guide copied to clipboard
Method "createEncoder" in section 3.2.1
Hi :-)
Thanks for the great guide !
I'm currently reading it and have small remark : in section 3.2.1, the example encoder creation method is def createEncoder[A]
However, the section 3.1.2 explanation gives the method name instance
as being the idiomatic. From my understanding, it would then be more idiomatic to name the 3.2.1 method instance
too ? Plus, it'd make it even more clear imo (right now, I'm only 90% sure that I'm correct that createEncoder
is actually the instance
idiom).
WDYT ?
Hi Nicolas,
Thanks for your feedback. I vaguely remember considering this when writing
the chapter... IIRC I came to the conclusion that, while instance
is a
fairly idiomatic name, it seemed a bit cryptic to introduce is as the first
name in the guide. It's definitely not clear-cut though. There may be merit
in rewriting it as you suggest. I'll give it some more thought.
Cheers, Dave
On Thu, Apr 27, 2017 at 3:19 PM Nicolas Dalsass [email protected] wrote:
Hi :-) Thanks for the great guide ! I'm currently reading it and have small remark : in section 3.2.1, the example encoder creation method is def createEncoder[A]
However, the section 3.1.2 explanation gives the method name instance as being the idiomatic. From my understanding, it would then be more idiomatic to name the 3.2.1 method instance too ? Plus, it'd make it even more clear imo (right now, I'm only 90% sure that I'm correct that createEncoder is actually the instance idiom).
WDYT ?
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/underscoreio/shapeless-guide/issues/42, or mute the thread https://github.com/notifications/unsubscribe-auth/AAOI52fwo_josL5RQaIPFa56pT3cz6KSks5r0KPsgaJpZM4NKSGe .