lambdas; arrays and records in expr; multi-argument functions

This commit is contained in:
Quinn Dougherty 2022-04-22 15:46:22 -04:00
parent 7035b581a6
commit 1984dd55b4

View File

@ -26,7 +26,7 @@ Think of javascript's list unpacking notation to read our variable-argument func
<expr> ::= <term> + <expr> | <term> - <expr> | <expr> .+ <expr> | <expr> .- <expr> | <term> <expr> ::= <term> + <expr> | <term> - <expr> | <expr> .+ <expr> | <expr> .- <expr> | <term>
<term> ::= <power> * <term> | <power> <term> | <power> / <term> | <power> .* <term> | <power ./ <term> | <power> <term> ::= <power> * <term> | <power> <term> | <power> / <term> | <power> .* <term> | <power ./ <term> | <power>
<power> ::= <factor> ^ <power> | <factor> .^ <power> | <factor> <power> ::= <factor> ^ <power> | <factor> .^ <power> | <factor>
<factor> ::= <number> | <bool> | <symbol> | ( <expr> ) | <symbol>(<symbol>) <factor> ::= <number> | <bool> | <symbol> | ( <expr> ) | <array> | <record> | <record>.<symbol> | <symbol> => <expr> | <symbol>(<symbol>) | <symbol>(<symbol>, <symbol>) | ...
``` ```
## Data structures ## Data structures
@ -41,7 +41,7 @@ Think of javascript's list unpacking notation to read our variable-argument func
``` ```
<statement> ::= <assign> | <assignFunction> <statement> ::= <assign> | <assignFunction>
<assign> ::= <symbol> = <expr> <assign> ::= <symbol> = <expr>
<assignFunction> ::= <symbol>(<symbol>) = <expr> <assignFunction> ::= <symbol>(<symbol>) = <expr> | <symbol>(<symbol>, <symbol>) = <expr> | ...
``` ```
## A squiggle file ## A squiggle file