in reply to pragmatic module idea

I think it's kind of silly to write a module to save people having to write one line of code. It's not a particularly difficult line of code, either.

Replies are listed 'Best First'.
Re: Re: pragmatic module idea
by John M. Dlugosz (Monsignor) on Dec 16, 2002 at 21:11 UTC
    Well, we have prior art:

    lib, base, and File::Slurp. I remember when overload wasn't a pragma but you had to update the hash yourself. For that matter, isn't strict just changing one variable?

    —John

      You're right about strict, because it's encapsulating non-obvious behavior, but I don't use lib, base, or File::Slurp. (The pragmas are less defendable on the same idea, but File::Slurp has crossed a line of encapsulation.)

      If you think it's necessary to write a module to encapsulate an assignment to %INC, go ahead. I think it's of dubious value -- of the times I needed to fake a module, I had to do several other things at the same time.

      My instinct is to say that the type of people who would need this module already know how to do what it does and are likely to do it themselves.