Live data from Hacker News

What is Modern Perl

josetteorama.com

41–46 of 46 posts

Re: What is Modern Perl

#41
post #30

Earlier quoted context omitted.

I started in 2003 or so, and got into it more seriously because I ended up with customers to support using Perl software. Perl is an amazing language, and with many modern perl approaches, it's wonderful. This being said like most frameworks it is extremely important to know when to leave the framework or leave things out. While I LOVE working with Moose, my own projects are very heavily stored procedure centric and…

David Wheeler (theory) started working on a stored procedure centric project a while back and as a result extracted the DBIx::Class connection logic into DBIx::Connector - which I have a feeling you're already using. I spent a fair amount of time hanging out in #ledgersmb a while back and in spite of being the project founder of DBIx::Class, I don't think I ever felt I had a convincing argument for using it, so hones…

Glad to see you again.

Actually some of your recommendations are pending getting rid of old code (we simply can't move everything to PSGI when we have the mixture of old and new code we have, so it's CGI only for now still). However we are giving hard thought as to the best way to do so and I expect that as we continue that process things will become more PSGI friendly until it is just a matter of changing one sub somewhere.

I should note you have convinced Josh Drake on the merits of DBIx::Class for other projects though.

Finally I think it is worth noting that I think that in the 1.4 tree we've come out (I hope) of the contageous effect of the bad SL code, and so the coding styles which evolved so much during LSMB 1.3 are being formalized and moved to Moose in 1.4.

Re: What is Modern Perl

#42
post #24
post #7

In perl culture, "Modern Perl" refers to bad programming by a core group of egocentric, sanctimonious developers who are to Perl what Lennart Poettering is to Linux. There are now dozens of CPAN modules with names like "common::sense" and "Modern::Perl" that provide no useful code, but introduce packaging dependencies and administrative overhead in the name of not having to type "use strict;" out by hand. Modern Perl…

I actually despise Moose as much as I despise blindly over-doing OO. To me Modern Perl meant tackling problems in a much more Lisp-inspired way (via lexical scoping, anonymous functions, closures, lists, etc) ... but in Perl. Kind of like "Higher Order Perl." I had the impression it was more a cultural shift, a renewed interest in Perl and people wielding it much differently. There's a different CPAN web interface[1]…

We moved to Moose only in the last year, and the reason was that at the time we started LedgerSMB 1.3, Moose was still relatively immature at least in the versions shipping with supported Linux distros. We felt it was an immature technology with too many dependencies to build our software on at that time (2007). After the 4 year development cycle and a release that happened only slightly after Duke Nukem Forever, we had cleaned up a significant part of the codebase, and Moose had changed.

Moose is a bit heavyweight. It may not be what you want in some applications. However, it strikes me as an inspiring example of design done right, and for that reason it's worth learning.

I think this exemplary aspect is why Moose has had the impact it has, not only being somewhat widely used, but also defining approaches that many other object approaches have borrowed. The fact that things are declarative is very helpful.

Re: What is Modern Perl

#43

I'm torn between thinking there is value in learning some Perl and not really knowing that value might be. I've found a lot of embedded wisdom in the "old school" stack. If you edit in vi, add some sed / awk / grep, and learn some bash, you'll find these tools start to come together and leverage one another up substantially. Perl might be more post-Bell Labs but it still was written and used by smart people to Get St…

>>But it isn't as approachable as Python.

Minimalism, is both an advantage and a curse. You may be able to learn python quickly, and that is because the syntax and semantics are designed with a goal to do that. But unfortunately that is not the only problem programmers have, Learning how to program is problem only for first few weeks of your programming career, there after its hardly a problem. Beyond that verbosity becomes a curse, once you begin to understand what 10's of lines of code do, you wonder why you even need 10's of lines of code when something can be expressed more elegantly.

In my experience people complain about learning Perl for the same reasons why they don't get awk/sed/tr and other text processing utilities. Tools like that are a little difficult to start with, but offer tremendous advantages. Skip learning them, and suddenly you put yourself in a situation where you start your eclipse and write Java programs for every small bit of text processing task. That sucks up your time, effort and code forever. So its better to learn tools that are better designed to solve such problems.

>>and I'm not sure why Perl would be better.

Perl and Python are both excellent languages, so you find a range of problems that can be solved in both languages well. But try solving problems that Perl was specifically designed to solve, Pick up the book Higher Order Perl by Mark Jason Dominus(Its Free) and see for yourself how Perl helps you solve a certain kind of problems. I'm sure its the same case with Python too! Its good for academia, as its easy psuedocode.

Problems that can be solved in both Python and Perl can obviously be solved in any of them.

>>So to my mind, Perl is something of a sysadmin tool, better than bash and very useful for a workload focussed on system and file processing, on *nix, without much service to HTTP. I'd love to hear how it pays returns for people more focussed on back-end support of web development.

You have just described a very small subset of problems Perl can solve. Perl is used for developing very large application in nearly almost every industry.

Web programming != Entire Programming world.

Much of the software world never writes a web page. And they do programming too. But like us they don't tweet/Facebook/blog every time they finish writing a class.

Re: What is Modern Perl

#44

Writing a book on Modern Perl is nuts. As the author of this post points out, there have been about twenty releases since Perl 5.6, when the book was published. Features like the "switch" and "state" keywords have been introduced. If you look away too quickly, another database interface crops up, or people are doing objects differently. Perl changes so often that writing about it is like trapping a unicorn. It's impr…

Writing a book on Modern Perl is nuts.

I've written two.

Perl changes so often that writing about it is like trapping a unicorn.

Not really. I document things with staying power. For example, I documented only the parts of smart match that are easy to explain. Everything else is up for debate, and thus not really worth recommending. (Besides, I'm not trying to replace the documentation.)

Re: What is Modern Perl

#45

I'm torn between thinking there is value in learning some Perl and not really knowing that value might be. I've found a lot of embedded wisdom in the "old school" stack. If you edit in vi, add some sed / awk / grep, and learn some bash, you'll find these tools start to come together and leverage one another up substantially. Perl might be more post-Bell Labs but it still was written and used by smart people to Get St…

There is no One True Path.

But there's probably a great deal more value to be had to knowing just one of the big three scripting languages (Perl|Python|Ruby) deeply than in knowing just a smattering of each.

Re: What is Modern Perl

#46
post #7

In perl culture, "Modern Perl" refers to bad programming by a core group of egocentric, sanctimonious developers who are to Perl what Lennart Poettering is to Linux. There are now dozens of CPAN modules with names like "common::sense" and "Modern::Perl" that provide no useful code, but introduce packaging dependencies and administrative overhead in the name of not having to type "use strict;" out by hand. Modern Perl…

Way to go to start your career here. Would your opinion be still valid without attacks on 'random' (as in totally unrelated) people? Your post might've been a well founded rant against the topic at hand, unfortunately you've lost any credibility by default when you added specific and personal insults. Poor taste..

You have a fucked-up definition of "career."
Post reply on HN