Luke Ivers wrote:
I, for one, did NOT find this to be the case... and I sure see a lot of
confused people on this list.
Ruby is just a programming language. Yes, it gives you some great
syntactic sugar and terseness. But there will still be things that take
some figuring out. Hell, I've seen some stuff in rails code that would
give Perl a run for its "crypticness".
Sorry, but I just think this "oh it reads just like English" stuff is a
bunch of hooey. Reads like stilted, oddball English is more like it...
and English that if you get one thing wrong, just doesn't do what
you want.
<rant>
So, just to get this straight: you're complaining that a programming language acts like... a programming language. You can't change the fact that syntax errors are syntax errors... and adding in too many aliases, etc., will just make the language huge and bloated.
It does read more like English than any other programming language I've used... but making it read exactly like English would be a horrible idea. Talk to a semanticist or linguist some time and ask them how well structured of a language English is. The point of a programming language is the ability to get your point across and tell the machine exactly what you want it to do. The more general you allow the programmers to be, the slower the language as it has to deal with more and more branching paths while interpreting.
So: Ruby is a great balance. It takes all the stupid, horrible crap that is English, and all the stupid, horrible crap that is programming logic, and walks a damn fine line down the middle of them. No one (or at least, no one who knows what they're talking about) is trying to say that it reads like the English you speak... just that it's as close as it can get to that without completely bloating the language to death.
</rant>
Sorry, had to get that off my chest; I've heard a lot of people making the particular statement you did recently, and this seemed like an appropriate place to bite back. Nothing personal at all.
Heh. That's funny. I wrote my post because I had seen so many people talk about how Ruby is superior because it's more like English... and I have seen a lot of talk about how Ruby and Rails make it so easy to whip out apps. It is... if (just like any tool) you know what you're doing.
I think Ruby and Rails are great... but there are plenty of difficult concepts in both that take some learning. I think the level of confusion that I've seen on this list for over a year now is ample illustration of that.
No I don't expect a programming language to read like English... that was exactly my point. Why then is reading more like English a supposedly good thing? Making a language read more like English is accomplished through syntactic sugar and magic; magic always comes at the cost of additional cerebral load.
Once again... I love Ruby and Rails... I am simply quibbling with what I see as a common, mindless argument for championing Ruby and Rails. There is plenty of better ammo.
But I'm also falling back into my reflexive posting of my contrary opinions... which doesn't really forward anyone's knowledge... and is really just as lame as saying "oooh, Ruby's great cuz you can say 4.days.from.now"... so it's back into my hole with me.
b