some rudimentary list operations

This commit is contained in:
Aidan 2020-07-24 19:58:09 -07:00
parent 5d538d4a0b
commit 15e294085c
No known key found for this signature in database
GPG key ID: 327711E983899316
2 changed files with 98 additions and 0 deletions

View file

@ -59,6 +59,28 @@ func GenFuncTable() ast.FuncTable {
Args: 3,
},
"len": &ast.Function{
Function: Len,
Name: "len",
TimesCalled: 0,
Args: 1,
},
"head": &ast.Function{
Function: Head,
Name: "head",
TimesCalled: 0,
Args: 1,
},
"tail": &ast.Function{
Function: Tail,
Name: "tail",
TimesCalled: 0,
Args: 1,
},
"export": &ast.Function{
Function: Export,
Name: "export",