Hacker News new | past | comments | ask | show | jobs | submit login

Personally, I don't think "readable by people that don't know the language" is a reasonable feature to optimize a language around.

And if you go on that direction, almost the everything on the language is a larger roadblock than an oddly placed conditional.




I never suggested we ”optimize the language around this feature.” I only suggested that it is a higher virtue than some user on HN’s subjective concept of ”elegance.”

What do you think is more important: the speed at which C programmers can navigate your code base, or one person’s subjective idea of ”elegance”?


"Elegance" can mean many things, some irrelevant, some very important. But the speed at which C programmers can navigate some non-C code is absolutely irrelevant.

Specifically about Ruby, with it's infinite levels of metaprograming and "you can even redefine the meaning of blank space" philosophy, it's not 'unless' that will stop anybody.


I wrote Ruby for years (for fun). I always had to stop and think twice about 'unless' and translate it into 'if not'.


Exactly the same here. I write Ruby for a living and use 'unless' where it makes sense or fits with existing code.

That said, when reading code, I often have to pause and mentally translate "unless" to "if not". This is especially true for more complex logic.

Elegant, yes. Additional mental overhead at times, certainly.




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

Search: