Fancy strings in Scala 3

PHOTO EMBED

Mon Apr 25 2022 20:11:57 GMT+0000 (Coordinated Universal Time)

Saved by @joel113 #scala

object LowerCased:
  inline def from(inline s: String): LowerCased = ${ fromImpl('s) }

  import scala.quoted.*
  private def fromImpl(s: Expr[String])(using Quotes): Expr[LowerCased] = 
    ???
content_copyCOPY

https://softwaremill.com/fancy-strings-in-scala-3/