in reply to "advanced" Perl functions and maintainability

I've never thought maintenance programmers should be the least experienced ones. It's not so much experience but temperment that divides people into which phase they work in, I think, although no one seems to think about that when making the assignments.

I've been at a few places that get nervous when they look at my code and see a lot of map statements. I don't tend to write dense code, so it's not that they can't pick out the flow. They just don't map yet. However, I'm not going to give it up. For the money I get paid, they should use all my skills. Otherwise they could hire at the same price three guys who don't know map.

There are things that I just don't use for client work: source filters, Spiffy, typeglob magic, odd B hacking, and so on. That stuff is a little much to ask of the typical Perl programmer who's just doing his day job (instead of someone like me who writes about Perl, publishes a magazine about it, and works with Randal).

In all of this, people need to develop good reading habits in themselves and the people they have to work around. Some places I've worked even have a "team library" with all the right books (with several copies in some places). If you run into something you don't know, pull out the Camel book and learn about it. Write a couple of dinky scripts to play with that feature without worrying about making it work in a big program that has sorts of other (broken) things going on. Don't get turned off because it seems weird at first. Everything seems weird at first.

Along with that, we encourage people to develop a style guide, and talk about hwo they are going to code. This can include the features they are not going to use along with a justification for it (since they'll have to explain it to every new person anyway). Often, there isn't any good reason other than FUD, and the exercise of writing it out usually makes them realize that.

In the end, if we are going to code to the lowest common demoninator, we can get rid of strict, lexicals, and subroutines. :)

--
brian d foy <bdfoy@cpan.org>

Replies are listed 'Best First'.
Re^2: "advanced" Perl functions and maintainability
by geektron (Curate) on Dec 12, 2004 at 19:39 UTC
    In the end, if we are going to code to the lowest common demoninator, we can get rid of strict, lexicals, and subroutines. :)

    i think this is what i was getting at. while i won't pretend to say my skills hold a candle to yours, i can tell by looking at the old codebase at this company that i'm the most experienced person that's been there ... i know i need to do more to document things, but i'm always stuck in the trenches.

    i do tend to write a ton of little toy scripts to make sure function X does what i thought it did ( my homedir is full of them ), and refer back to them when needed.

    i want to leave behind a way that people can learn something as well as have tight code that works properly.

    just to clarify -- i don't think mainentance programmers have to be of a 'lesser' skill set than the original developer. i'm also a big fan of the Kernigan quote mentioned in another reply, and it has proven true at this job, because i've fixed longstanding bugs that the original (no longer at the company) developer just couldn't fix.

    overcoming the managerial resistance is the biggest issue at this place. i've had a hell of a time convincing him that we need things like *shared* libraries, better source control, etc. because he's more concerned with ease of tossing a client their code if they leave than with making the developers' jobs simpler and easier.