provided code
This commit is contained in:
15
src/main/wacc/Main.scala
Normal file
15
src/main/wacc/Main.scala
Normal file
@@ -0,0 +1,15 @@
|
||||
package wacc
|
||||
|
||||
import parsley.{Success, Failure}
|
||||
|
||||
def main(args: Array[String]): Unit = {
|
||||
println("hello WACC!")
|
||||
|
||||
args.headOption match {
|
||||
case Some(expr) => parser.parse(expr) match {
|
||||
case Success(x) => println(s"$expr = $x")
|
||||
case Failure(msg) => println(msg)
|
||||
}
|
||||
case None => println("please enter an expression")
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user