- About Scala
- Documentation
- Code Examples
- Software
- Scala Developers
Implicit class + inline class SID (Scala Improvement Document)
Mon, 2011-08-22, 13:30
Cross-posting to scala-language + scala-internals because I wasn't sure where else to push this.
You asked for it, and it's ready for public viewing! Here is a modified proposal for implicit classes that includes the ability to inline classes. The ulitmate goal of this proposal is for better 'implicit' performance within Scala. Specifically for the extension method + typeclass/typetrait patterns embedded in Scala implicits.
Please take a look and offer constructive feedback!
https://docs.google.com/document/d/1k-aGAGmbrDB-2pJ3uDPpHVKno6p-XbnkVHDc07zPrzQ/edit?hl=en_US
Note: This proposal does not include any syntax sugar fixes for defining typeclasses. I have an alternative, much more controversial, SID that outlines an annotaiton-based approach to generating typeclass boilerlate. I can send it to those who are interested, because it's designed to be acheived via annotations + a compiler plugin currently.
- Josh
You asked for it, and it's ready for public viewing! Here is a modified proposal for implicit classes that includes the ability to inline classes. The ulitmate goal of this proposal is for better 'implicit' performance within Scala. Specifically for the extension method + typeclass/typetrait patterns embedded in Scala implicits.
Please take a look and offer constructive feedback!
https://docs.google.com/document/d/1k-aGAGmbrDB-2pJ3uDPpHVKno6p-XbnkVHDc07zPrzQ/edit?hl=en_US
Note: This proposal does not include any syntax sugar fixes for defining typeclasses. I have an alternative, much more controversial, SID that outlines an annotaiton-based approach to generating typeclass boilerlate. I can send it to those who are interested, because it's designed to be acheived via annotations + a compiler plugin currently.
- Josh