4 ms·
Interesting that you should complain about Perl, then say that you've moved to Ruby, because in my opinion, Ruby is no better constructed than Perl. The bigges
by timr 18y ago
Interesting that you should complain about Perl, then say that you've moved to Ruby, because in my opinion, Ruby is no better constructed than Perl. The biggest crime I see attributed to Perl -- flexible syntax -- applies to Ruby in spades. (Ruby's actually much worse, since it allows you to do obtuse metaprogramming tricks that would make a good Perl coder blush. Not to mention the fact that it's a LOT slower.)
I think the main difference is that Perl is old, and Ruby is new. Geeks are a cantankerous, competitive bunch, and it's harder to be the hot new guy with mad skillz if you're working in a well-established language that has a huge base of expertise and good programmers. As a result, lacking outside pressures, programmers will always migrate to the flavor of the week, so that they can stand out from their competitors.
- lacker 18y agoRuby gets the basics of object oriented programming right. You should not have different syntax for different object types. In Perl, even for things like assigning to a variable or passing an argument to a function you need to know the types. It is nearly impossible to replace a list or a hash table for another datatype later. Ruby gets the simple stuff like this right.
- timr 18y agoRuby's way of doing things is not necessarily "right". It's different. In particular, if your fundamental types are fundamentally different, there's a strong argument that they should have different interfaces. Object-oriented programming does not require that all types be polymorphic, and pretending that they are is a source of confusion.