Skip to content

Conversation

jschatz1
Copy link

@jschatz1 jschatz1 commented Oct 3, 2022

Initial AST for program, comments, variable declarations, and variable reassignment.

@jschatz1
Copy link
Author

jschatz1 commented Oct 6, 2022

One thing I am not sure of is if "everything is a function" in foi or not. @getify what's your thoughts?

@getify
Copy link
Owner

getify commented Oct 6, 2022

@jschatz1

No, not everything is a function.

For example, empty, import, def, deft, defn, over, as, and default are all keywords. We also values, like numbers and strings, as well as records and tuples, and those are all definitely not functions.

However, all operators are functions, and most non-identifier symbols are operators/functions. For example, the . looks like it might be a special syntax, but it's actually a binary accessor-operator, so x.1 can also be done as | . x 1 |. Same with the .. tuple-range operator and the ... spread operator.

Exceptions: the ; and : separators, the , comma (list separator), sigils like ^ (return) / & (pick) / % (map-field), the # pipeline topic / def-block context, the -> function-return-type marker, and several sets of paired delimiters like " double-quotes (string delimiters), | | evaluation-expression (lisp) form, < and > record/tuple delimiters, <{ }>, { }, [ ], ( ), ?/ /, etc.

@getify getify force-pushed the main branch 4 times, most recently from ac0e80f to 501e097 Compare October 23, 2022 14:47
@getify getify force-pushed the main branch 5 times, most recently from d387f73 to e50541b Compare November 7, 2022 21:53
@getify getify force-pushed the main branch 3 times, most recently from 0658e9f to 9fc3d89 Compare November 15, 2022 22:28
@getify getify force-pushed the main branch 14 times, most recently from 6be7e59 to 345b7d4 Compare November 30, 2022 06:09
@getify getify force-pushed the main branch 13 times, most recently from e3bc8da to 1bdb48c Compare December 20, 2022 13:50
@getify getify force-pushed the main branch 9 times, most recently from 78e9f36 to 4df922f Compare December 30, 2022 22:51
@getify getify added the On hold Inactive label Dec 31, 2022
@getify getify force-pushed the main branch 3 times, most recently from 2b2880c to 5dff0ed Compare December 4, 2023 02:56
@getify getify force-pushed the main branch 3 times, most recently from 6b171f6 to 6050fd5 Compare December 15, 2023 17:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
On hold Inactive
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants