ALFS.pm drawbacks

Neven Has haski at sezampro.yu
Mon Feb 12 05:38:41 PST 2001


On Mon, Feb 12, 2001 at 04:43:46AM +0100, David Siegel wrote:
> > It would be nice if we could make it work with some older perl versions, 
> > at least 5.00503, since there are a lot of people still using it.
> 
> Agreed. I didn't want to introduce another requirement. Just happend...
> The main problem is Carp::Heavy, right? It's used by croak(). Afaik, croak()
> isn't new in perl 5.6. I will take a look at the code, but I don't have
> an old perl around yet.

croak() isn't, but Carp::Heavy is. Correct me if I'm wrong, but I don't think
that it's really needed for croak() to work. "use Carp" should be enough.

<quote from="perldoc Carp::Heavy" perlver="5.6.0">
	NAME
	       Carp::Heavy - Carp guts

	SYNOPIS
	       (internal use only)

	DESCRIPTION
	       No user-serviceable parts inside.
<quote>

And that's it. I'm not sure why you used it ?

After removing the above, there's only one thing more.
I couldn't find "rel2abs", "File::Spec::Functions" seems to be new in 5.6.0.
But I could write a small sub or just add a few lines to replace it if we don't
find a better solution ?

> Yeah, just start hacking. No need to wait.  /me will merge your changes
> more carefully next time :)

Heh, great. :) 

May I just suggest something? 
Have you read "linux/Documentation/CodingStyle" ? :) There are a lot of good 
points made there, especially those about indentation. I find code _much_ 
easier to read, when tabs are 8 spaces long. 
But please, this is only a suggestion, so don't get me wrong, I wouldn't mind 
if it stays like this.

> btw, is there a reason why fix_text only fixes the first line of the text?

Not really. That's just "minimum" that was needed so we don't have any 
problems with that extra whitspace in some tags.

Your " $text =~ s/(^\s+|\s+$)//gm; " sounds just fine. :)

Neven







More information about the alfs-discuss mailing list