Replies: 1 comment 2 replies
-
If you are going the other direction you could do: I'm sure there's more you can do. |
Beta Was this translation helpful? Give feedback.
-
If you are going the other direction you could do: I'm sure there's more you can do. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I really liked the semantic showing the direction-of-information in an assignment that
<:
gives. Moreover,:>
is currently the flow operator (compose-left-to-right). Initially, I thought that was kind of a cool symmetry with the assignment operator.But the more I interact with
< >
Records/Tuples, the more I find these operators using the<
and>
characters perhaps being more confusing. Perhaps the intended semantics are too subtle/clever to matter, and the similarity will just be confusing in the long run.So...
What would be a better assignment operator?
I am pretty firmly against using
=
in any way for that purpose, as I've always disliked the conflation with assignment and equality-comparison.?=
and!=
are the equality/inequality operators already, and I don't see that changing.I kind of think that
:
should be part of the assignment operator, since:
is used for initialdef
definitions, as well as field name definitions in Records.What about
::
? Is that too weird?As a FP language, Foi needs to straddle a fine line here. Re-assignment must be possible, but it should stand out and be pretty obvious that it's happening.
What would be a better flow (flow-right) operator? Or is
:>
fine as-is, if we already change the assignment operator?Originally, I had
>>
but then realized that would have potential grammar ambiguity with the closing tags of nested Records/Tuples.Also, the pipeline operator is
#>
and I really like that because then the#
is available as the topic token in the pipeline.Beta Was this translation helpful? Give feedback.
All reactions