Using .tupled method when companion object is in class

前端 未结 4 1034
我在风中等你
我在风中等你 2020-12-13 18:32

I am in the process of migrating from Slick to Slick 2, and in Slick 2 you are meant to use the tupled method when projecting onto a case class (as shown here h

4条回答
  •  眼角桃花
    2020-12-13 18:49

    To build on some of the other comments you could do the following as well since tuple is calling the generated default apply method for the case class.

    object Person {
      ...
      def tupled = (this.apply _).tupled
    }
    

提交回复
热议问题