Skip to content

Instantly share code, notes, and snippets.

@karthik20522
Created May 25, 2019 06:45
Show Gist options
  • Save karthik20522/cc0de39c2b8ef2d83707fed298161c8e to your computer and use it in GitHub Desktop.
Save karthik20522/cc0de39c2b8ef2d83707fed298161c8e to your computer and use it in GitHub Desktop.
select name,age from users
def select: Parser[Select] = "select" ~ repsep(ident, ",") ^^ {
case "select" ~ f => Select(f: _*)
}
//output: Select(List[String]("name", "age"))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment