feat: imports parser

This commit is contained in:
2025-03-13 08:18:44 +00:00
parent 905a5e5b61
commit e881b736f8
3 changed files with 32 additions and 6 deletions

View File

@@ -72,7 +72,7 @@ def frontend(
): Either[NonEmptyList[Error], microWacc.Program] =
parser.parse(contents) match {
case Failure(msg) => Left(NonEmptyList.one(Error.SyntaxError(msg)))
case Success(prog) =>
case Success(ast.PartialProgram(_, prog)) =>
given errors: mutable.Builder[Error, List[Error]] = List.newBuilder
val (names, funcs) = renamer.rename(prog)