Q&A - scalastyle - illegal start of simple expression: Token(RPAREN,),135,))

51 Views Asked by At

The original codes:

  def args: List[String] = List(
    "parameter1",
  )

When run scalastyle, the error message is:

illegal start of simple expression: Token(RPAREN,),135,))

The error message didn't show any information.

2

There are 2 best solutions below

3
On

It's because of extra comma. So the correct way is:

  def args: List[String] = List(
    "parameter1"
  )
1
On

Error is because of an extra comma

corrected code : def args: List[String] = List( "parameter1" )