Skip to content

Method surface for methods with multiple parameter lists fails with Scala 3 #3355

@OndrejSpanel

Description

@OndrejSpanel

Following code compiles fine with Scala 2 but results in error with Scala 3.

  case class ParamLists() {
    def mutipleParamLists()(): Unit = ()
  }

  Surface.methodsOf[ParamLists]

Error is:

missing argument list for method mutipleParamLists in class ParamLists

def mutipleParamLists()(): Unit

  case class ParamListsAB() {
    def mutipleParamLists(a: Int)(b: Int): Unit = ()
  }

  Surface.methodsOf[ParamListsAB]

Errors are:

wrong number of arguments at pickler for (a: Int)(b: Int): Unit: (Main.ParamListsAB#mutipleParamLists : (a: Int)(b: Int): Unit), expected: 1, found: 2

object Tuple2 in package scala does not take parameters

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions