Fix the parser, make the function name optional.

This commit is contained in:
2023-10-07 11:25:49 +02:00
parent 736d27953f
commit ca26d0ea40
4 changed files with 17 additions and 4 deletions

View File

@@ -27,7 +27,7 @@ pub struct Program {
#[derive(Clone, Debug, PartialEq)]
pub enum TopLevel {
Statement(Statement),
Function(Name, Vec<Name>, Expression),
Function(Option<Name>, Vec<Name>, Expression),
}
/// A Name.