prog: (monkey)
prog ([personal profile] prog) wrote2007-04-26 11:38 am
Entry tags:

Perl 6

I feel the gentle winds of conventional wisdom buffeting me towards Ruby.

Is there a practical reason why I might want to do this? Coz if I learned it just for S&G but then didn't immediately start using it for serious, I'd forget it.

"Dude, Rails" is not a sufficient reason, unless you can tell me why I'd want to use Rails over any Mason-based solution.

(Referring to Ruby as "Perl 6" is from [livejournal.com profile] xach, and the funniest in-joke I've heard all week.)

[identity profile] jaq.livejournal.com 2007-04-26 04:10 pm (UTC)(link)
Is there ever a practical reason for learning a programming language when you already know several that would 'do the job'?

I like Ruby. It manages to be simple and terse at the same time. I can't write Perl without a reference book on the desk, whereas in Ruby I can generally guess methods I don't know and they will work.

I learned about closures through learning Ruby, and now it is frustrating to use a language without them. It's certainly not the only language with closures but they are a central part of Ruby style.

I also use Rails for a few personal projects, but I know nothing about Mason so I can't compare.

The whole JRuby thing with Sun backing it is worth watching too.

[identity profile] novalis.livejournal.com 2007-04-26 04:49 pm (UTC)(link)
Mason does code in templates.
Rails does that, plus model/view/controller routing, plus object-relational mapping.

But it's no reason to learn Ruby. Learn Python instead, and use Pylons, which is just the same as Rails except a bit less magic.

Or maybe Maypole is good enough that you can just use your existing Perl skills in a similar framework.

[identity profile] chocorisu.livejournal.com 2007-04-26 04:49 pm (UTC)(link)
I get the impression that Ruby is one step closer to Lisp than Python. Very expressive, clean syntax, but lacks mature libraries and has severe performance penalties. In other words, a great prototyping language and perfect for smaller projects.

I haven't had a chance to sit down and learn it but I looked at the syntax and it seems like an easy one to pick up.
cnoocy: green a-e ligature (Default)

[personal profile] cnoocy 2007-04-26 04:58 pm (UTC)(link)
Ruby seems fine. But I find it hard to take a language seriously in which "5.days.from_now" is a valid expression.

[identity profile] karlvonl.livejournal.com 2007-04-26 05:03 pm (UTC)(link)
I personally love Ruby, but that's probably mostly because it's the scripting language that I learned, rather than say Perl or Python. But if you already know Python, I'm not sure there's a compelling reason to switch to Ruby. That is, unless you're a big fan of object-oriented programming. Ruby is object-oriented through and through, as opposed to Perl and Python which sort of have OO bolted on. Heck, Ruby is the only language I've ever used that's so OO that you can actually call methods directly on literals, e.g.:

"Hello world".reverse
3.15.round

Also, Ruby's introspection and meta-programming facilities are very powerful, and make it a popular choice for developing domain specific languages.

And then, of course, there's the cartoon foxes:
http://poignantguide.net/ruby/whatisit.html
Chunky bacon!
ext_2472: (Default)

[identity profile] radiotelescope.livejournal.com 2007-04-26 06:35 pm (UTC)(link)
Python also has methods on literals. "hello".upper() returns "HELLO".

Mr. Grumpy

[identity profile] taskboy3000.livejournal.com 2007-04-26 10:52 pm (UTC)(link)
Syntax is overrated.

There, I said it.

I write code to make money. Sure, I enjoy coding, but really, I like money more. The language feature that is important to me right now is: can I create a deployable application with it?

For desktop apps, Python and Java fit this need very, very nicely. For ASP apps, it's PHP or Perl for me.

Size matters. Ruby doesn't have the CPAN^Wlibrary repository or developer community that the other languages that were mentioned boast. It may some day. Ruby is a cool little language, but that's not all that important anymore. Great tech does not a product make.

Certainly, it is time to write the obitrary of Perl. It's a great language that's in maintenance mode now. Still useful, but it's golden years are over. Java is fighting to stay relevant. Without Sun chucking gobs of money at it, Java would have all but died by now. Without the healthy rivally of a vigorous Perl community, Python seems pretty much in maintenance mode too.

At least Ruby appears to have momentum, but where is it going? CGI/Templates/MVC isn't exactly cutting edge and continuations are syntactic sugar.

If I had to advise a new programmer, I steer them towards C++ or even .Net.
C++ is generally more useful but a complete in the balls to program. Even a little skill with .Net can net you a schelpy job in the bowels of corpamerica.

I'm a grumpy old man.