KacperFKorban / GUInep

Automatic UI forms for Scala 3 functions
https://kacperfkorban.github.io/GUInep/
Apache License 2.0
14 stars 0 forks source link

Support multiple parameter lists (and extension methods) #33

Open KacperFKorban opened 5 months ago

KacperFKorban commented 5 months ago

It should be possible to use methods with multiple parameter lists and extension methods with GUInep

e.g.

def addManyParamLists(a: Int)(b: Int): Int =
  a + b

enum IntTree:
  case Leaf
  case Node(left: IntTree, value: Int, right: IntTree)

extension (elem: Int)
  def isInTreeExt(tree: IntTree): Boolean = tree match
  case IntTree.Leaf => false
  case IntTree.Node(left, value, right) =>
    value == elem || elem.isInTreeExt(left) || elem.isInTreeExt(right)