Error : value ^^ is not a member of String

What could possibly be wrong when using the ^^ in a scala parser combinator example :

"ff" ^^(_ => FALSITY())

Did you imported import scala.util.parsing.combinator._?
Also, is the error real, meaning it comes from a real compiler like a build tool as sbt or does it comes from an IDE like IntelliJ?

I am making use of

import scala.util.parsing.combinator.RegexParsers

With regards to the compiler, I am making use of the sbt compiler :slight_smile:

Thanks a lot and good day

I am not familiar with the scala-parser-combinator library, but I am pretty sure scala.util.parsing.combinator._ is bringing a lot of implicits in scope.

When you do just scala.util.parsing.combinator.RegexParsers you are just importing one and using its name. First, in general, it is considered a bad practice to import named implicits. Second, judging for that name that works only for regexes, like "[1-9]+".r not for plain strings. So you may turn that String into a constant regex or just import _ instead of a single named one and it probably will just work.