Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

In my experience, everyone finds the syntax of their favourite language lovely - I love (mostly) C++.


Not me!

I don't like the syntax of Lisps, with the leading parenthesis to begin every expression.

I use it anyway because it's so useful and powerful. And I don't have any better ideas.


> leading parenthesis to begin every expression

well, that's not really what it is doing - it is saying apply this function to these parameters.


No, it's an s-expression... it may be a function call, but it may also be a macro, and inside a macro it may be a parameter list or a number of other things.


As someone who works almost exclusively in C++, the whole "most vexing parse" makes the syntax indefensible.


In my experience, people simply go "Doh, of course!" or don't write the wrong code in the first place. It has never caused me any real problems.

For those of you that may be curious, or not know C++, in C++ this:

    Obj x();
is a declaration of a function called x that returns an Obj. Whereas this:

    Obj x;
defines (possibly, depending on context) an instance of the type Obj called x.

Most people get over this pretty quickly.

If that is your main complaint about a language then the language doesn't have too many problems. Not that I'm suggesting that C++ doesn't have more serious problems.


I don't like how Python does lambdas, its indentation-based blocks, how there's both ' and ", I could go on.


I am an exception then. Rust may be my favourite language but the syntax is pretty awful and one of its biggest weaknesses. I also love Ruby but I am pretty meh about its syntax.


I don't think many people would start to use a language unless the found the syntax at least a little simpatico - but I guess they could be drawn by the semantics it provides.


I (almost) don't consider syntax at all when considering a language, just whether it's suitable for the task.

The exception is languages with syntax that require a non-standard keyboard.


I mostly chose languages due to semantics.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: