3 ms·
Ok, is not well articulated: > F# are all much more than syntax issues But some of the things that make F# unique are surfaced with the syntax. Is not just th
by mamcx 9y ago
Ok, is not well articulated:
> F# are all much more than syntax issues
But some of the things that make F# unique are surfaced with the syntax. Is not just there for the sake of it.
Pattern matching is the most obvious thing. The way the syntax present this aspect is close to perfect...
ie: I'm for fun building a language. I have tried a lot of ways to present some things, like Pattern Matching. I can't figure a better way without resorting to weird characters, unicode or text editors that not exist. (I replace "|" as separator but the basic structure is just the same).
Other ways the syntax is significant is in how it encourage curried functions, chaining and pipelines (with |>). The pipeline way is something that I truly adore. Wish F# was more into this, IMHO.
Not fan in how let have different meanings, neither the use of "," for tuples.
Also is confunsing why functions with "let sum a b" are truly different to "let sum(a,b)". Hate this (because suddenly pipelines and curried application not work anymore).
The making of "inmutable first" and marking some vars as "mutable" is something truly nice. Could be easier if it was "let" and "var" instead of "let mutable" but anyway. Is good.
Anyway, as a amateur language designer it make me more aware in how the syntax make a language better or more ergonomic and lead the way in how use it.
- sidlls 9y ago"Close to perfect" according to...you? Arguments from Syntax are closer to emacs vs vim or K&R vs Allman bracket/indentation flame wars than they are to meaningfully discussing differences between languages. It's so superficial compared to so many other things.
- mamcx 9y agoI have look at more than dozen languages, probably more (as research in how build one). So is not exactly according to me, but how is done in other languages. Anyway... try to design this, for example, and tell how you do it better ;)