Syntax is the lowest form of critique. The lowest. I cannot take it seriously.
Anyone agree / disagree?
Having said that, perhaps Elixir’s biggest mistake was going for a Ruby-like syntax instead of a JS one… /* just kidding : ) */
Syntax is the lowest form of critique. The lowest. I cannot take it seriously.
Anyone agree / disagree?
Having said that, perhaps Elixir’s biggest mistake was going for a Ruby-like syntax instead of a JS one… /* just kidding : ) */
Depends on the topic of the discussion. If we’re talking about beginner friendlyness and readablity I’d say syntax is very much a reasonable argument. As an extreme example elixir certainly beats brainfuck on that matter. Also given two languages being functionally equal but syntactically different I’ll always choose the more readable and/or familiar syntax.
On the other hand you’re correct that syntax is only a small part of judging the usefulness of a language, especially if we’re at a middle ground of familiarity to the syntax and not at the extremes (like again brainfuck).
Yep, correct, there is a place for syntax discussion and it’s right at the bottom of the list.
Which is basically what you imply, with
Tbh, for me the syntax is really important.
If it reads like rubbish, i take a quick step back.
Sure, there are other more important things, but syntax is a big one for me as a non-programmer.
Syntax is important.
Even though, languages are a tool for me and I usually pick the language/runtime that suites the problem to solve best (well, sometimes the decission is made by the businness people ).
Still, if I have two screwdrivers, one with and old wooden handle and one with a super grippy rubber handle, I’d prefer the one with the more ergonomic rubber handle.
The handle of the screwdriver is like the syntax of a language.
Agreed, syntax is important, but the expressiveness of the language matters too. There are two factors that are important to me:
Have you tried XSLT?
Try it for a couple of weeks and see if you feel the same way
Just reading XSLT made me have a horrible flashback. You gotta warn people.
The problem is that “rubbish” is entirely subjective:
For me the important things are:
Just looking at syntax is of little use. It is the big picture that matter.
Of course you can have a personal preference regarding syntax, but I rather program in a syntax I dislike that is consistent and well thought out then a syntax I like which isn’t.
To tie in to the thread: Debating syntax may be dumb but it is fun!
Overall syntax is important. Details like do/end vs begin/end vs {} are truly irrelevant. (Or position of piped-in argument…)
(I once saw an anti-Ruby rant where the poster claimed that begin/end was a mistake because it was so horribly verbose compared to {}, and that was it for any chance of me trying to seriously understand his argument.)
I think this S/N ratio mentioned earlier is a good point: you want maximum amount of information in shortest time. So you want syntax that packs everything into short and simple commands, with clear image what’s going on. E. g. OOP languages if not done correctly tend to force programmer to know entire structure, being stateless most of the time is preferable.
For me, immutability is a key - you cannot modify anything without explicit use of ‘=’, prevented many obscure bugs.
Wise words. When working on legacy apps or code I didn’t write I try to keep this in mind. Admittedly it’s not the easiest thing to do.
I think syntax is important too, however I agree that debating it can sometimes get silly
For instance, if a language has clearly been influenced by language X, and the creator of said language, and many of its users, actually like the syntax of language X - then it’s a bit pointless ranting about how the syntax of language X sucks and things need to be more like language Y particularly when you often find those who like the syntax of language X dislike the syntax of language Y
I’d argue that if you don’t know at least 5 disjoint languages, then you should not argue syntax. Otherwise you’re just arguing what you’re familiar with and not true syntax.
Now you should code brainf*ck if that doesn’t concern you.
I like a language that is economical with its tokens and accomplishes a lot with a chosen few applied in a consistent way. Smalltalk comes to mind and I do like it in part because of the syntax. But I think it’s because of what the simplicity means in practice as well. Not having a bunch of keywords that have to be kept in mind all the time frees you up to effectively design your own syntax. The syntax itself is just a few different ways to send messages, some necessary differences between classes/variables, etc., and that’s it.
When people try to create nice syntax by adding things it really can’t ever reach a good point.
With that said, I’ll take a language with keywords and a great way to express ideas (in f.e. a good type system) any day, because I think OP is actually pretty spot on. Syntax is nice to discuss because literally everyone can have an opinion, so it’s very inclusive, but at some point you have to get real and appreciate that we’re not just typing things, but encoding ideas, assumptions and guarantees. No amount of syntactical niceties can make up for a function head that can say literally nothing about what assumptions are made in the function.
Having a reading disability, syntax makes a very big difference for me. A few notes about trying to read code:
I’m sure there is plenty more. Elixir is genuinely easier for me to read than a lot of code. Good thing I really like it, too.
This is really interesting. How do you find indentation based scope delimiters?
My mother (dyslexia) “reads” layout first. In the German language and with some major fonts, she is able to read most words without looking at the letters, because her brain is wired to recognize the shape and pattern of the printed word. For foreign words, fonts and languages she needs to manually “parse” the words, letter by letter, whispering them out.