[22584] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 4805 Volume: 10

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Apr 2 09:06:29 2003

Date: Wed, 2 Apr 2003 06:05:08 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Wed, 2 Apr 2003     Volume: 10 Number: 4805

Today's topics:
    Re: .doc > .txt <no@email.com>
    Re: .doc > .txt (=?iso-8859-1?q?M=E5ns_Rullg=E5rd?=)
    Re: .doc > .txt <NoSpamPleaseButThisIsValid2@gmx.net>
    Re: .doc > .txt <tore@aursand.no>
    Re: creating virtual directories with urls (john harrold)
    Re: Deducing variable name during initialization <ubl@schaffhausen.de>
    Re: Deducing variable name during initialization <jll@soundobjectlogic.com>
    Re: Deducing variable name during initialization <ubl@schaffhausen.de>
        Help me with a Perl Script <congers@yoeric.com>
    Re: Help me with a Perl Script (Helgi Briem)
    Re: ICQ <bsd_devil@web.de>
    Re: OT: Regex - hard or soft 'g' <nospamkz15mapson@tellabs.com>
    Re: Perl editors <jussij@zeusedit.com>
        regex question <scare.crow@oz.land>
    Re: regex question (Anno Siegel)
    Re: regex question <scare.crow@oz.land>
    Re: regex question <tore@aursand.no>
    Re: regex question (Anno Siegel)
    Re: regex question <scare.crow@oz.land>
    Re: search and replace long hex string (Anno Siegel)
    Re: slow file access under windows (Michael Bickel)
        strict, global vars and 'require' <tunmaster@hotmail.com>
    Re: That's just plain WRONG (Sara)
    Re: Two perl-debugging question (Peter Scott)
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Wed, 2 Apr 2003 11:25:43 +0000 (UTC)
From: "Brian Wakem" <no@email.com>
Subject: Re: .doc > .txt
Message-Id: <b6ehbn$cf1$1@titan.btinternet.com>


"Tintin" <me@privacy.net> wrote in message
news:b6ecm6$4d0il$1@ID-172104.news.dfncis.de...
>
> "Brian Wakem" <sorry.no@email.com> wrote in message
> news:b6e9hi$4h819$1@ID-112158.news.dfncis.de...
> > I have been trying to find a way of converting any .doc file into plain
> > text, i.e. extract purely the text from it, formatting is irrelevant.
> >
> > I've been using some extremely crude methods (below) I have devised to
do
> > it, and it works for 95% of .doc files, but fails on the other 5%.
> > Different versions of word save files in different ways.  I cannot find
a
> > module to help with this and I can't find anything useful on google or
> > groups.google.  Does anyone know of a module or script, or just a good
way
> > of doing it?
> >
> >
> > # extremely crude method, where $doc contains
> > # the entire .doc file.  This worked for 190 of the
> > # 200 .doc files I tested it on.
> >
> > $doc =~ s/^.*?(\xD9\x00\x00\x00|\x00{90,})//s;
> > $doc =~ s/\x0D\x00\x00\x00\x00\x00\x00\x00\x00.*$//gs;
> > $doc =~ s/\x00{16,}.*$//gs;
> > $doc =~ s/\x09/ /g;
> > $doc =~ s/\x0D/<br>/g;
> > $doc =~ s/\x08/<br>/g;
> > $doc =~ s/\x07/<br>/g;
> > $doc =~ s/\x13//g;
> > $doc =~ s/([\x00-\x09]|[\x11\x12]|[\x14-\x19]|[\xA0-\xFF])//g;
> > $doc =~ s/\s*(EMBED|PAGE)[\w\s_().]*//g;
> > $doc =~ s/<br>\s+/<br>/sg; # html formatting
> > $doc =~ s/(<br>){4,}/<br><br><br><br>/sg; # html formatting
> > $doc =~ s/HYPERLINK "?[-\w@._:]*"?//sg;
>
> Whoa!  Doing it the hard way.  Use Win32::OLE and save it as a txt file
> (assuming a Windoze environment)


It's not a windoze environment.  It's would be running on Redhat 7.2

--
Brian Wakem




------------------------------

Date: 02 Apr 2003 13:13:53 +0200
From: mru@users.sourceforge.net (=?iso-8859-1?q?M=E5ns_Rullg=E5rd?=)
Subject: Re: .doc > .txt
Message-Id: <yw1x7kadcfta.fsf@daim.e.kth.se>

"Tintin" <me@privacy.net> writes:

> Whoa!  Doing it the hard way.  Use Win32::OLE and save it as a txt file
> (assuming a Windoze environment)

Assuming non-m$windows, the standalone program collection from
http://wvware.sf.net might be useful.

-- 
Måns Rullgård
mru@users.sf.net


------------------------------

Date: Wed, 02 Apr 2003 13:56:54 +0200
From: Wolf Behrenhoff <NoSpamPleaseButThisIsValid2@gmx.net>
Subject: Re: .doc > .txt
Message-Id: <3E8AD006.DF9C8C92@gmx.net>

Brian Wakem wrote:
> 
> I have been trying to find a way of converting any .doc file into plain
> text, i.e. extract purely the text from it, formatting is irrelevant.

Try Antiword: http://www.winfield.demon.nl/
It comes with source so you can translate it to Perl if you want to :-)

Wolf



------------------------------

Date: Wed, 02 Apr 2003 14:05:27 +0200
From: "Tore Aursand" <tore@aursand.no>
Subject: Re: .doc > .txt
Message-Id: <pan.2003.04.02.09.38.47.666336@aursand.no>

On Wed, 02 Apr 2003 10:12:18 +0100, Brian Wakem wrote:
> I have been trying to find a way of converting any .doc file into plain
> text, i.e. extract purely the text from it, formatting is irrelevant.
> [...]
> I cannot find a module to help with this and I can't find anything
> useful on google or groups.google.

You must be kidding;  Searching for this topic on groups.google.com comes
up with lots of relevant threads.

Also, on www.cpan.org you'll find a few modules which can help you out
converting Word (*.doc) files to Something Else (tm).


-- 
Tore Aursand


------------------------------

Date: 2 Apr 2003 05:27:35 -0800
From: jmh17@pitt.edu (john harrold)
Subject: Re: creating virtual directories with urls
Message-Id: <31d0e2b6.0304020527.2de06393@posting.google.com>

Eric Schwartz <eric.schwartz@hp.com> wrote in message news:<etoel4l6eny.fsf@wormtongue.emschwar>...

> 
> So you know the problem is with Apache configuration, and yet you ask
> on a Perl language newsgroup?  Um, okay.  That makes no sense to me,
> but presumably you think we're better suited than the people over on
> c.i.w.s.*.  Me, I'd have asked comp.lang.forth, since I know somebody
> who writes CGI in Forth.
> 
> -=Eric

actually i though that someone here would have encountered this in the
past. as a result i thought this audience would be good to ask. the
apache configuration was my first thought, though i'm open to other
suggestions. i'm truely sorry for wasting your time.


------------------------------

Date: Wed, 02 Apr 2003 13:22:37 +0200
From: Malte Ubl <ubl@schaffhausen.de>
Subject: Re: Deducing variable name during initialization
Message-Id: <b6ekbp$hb2$1@news.dtag.de>

Jean-Louis Leroy wrote:
> Hello,
> 
> is there a bit of magic that would make this possible?
> 
>         my $foo = Variable->new;
>         print $foo->name; # prints 'foo'

What should happen in this case

my $foo = Variable->new;
my $bar = $foo;

print $bar->name

?







------------------------------

Date: Wed, 02 Apr 2003 12:12:59 GMT
From: Jean-Louis Leroy <jll@soundobjectlogic.com>
Subject: Re: Deducing variable name during initialization
Message-Id: <lzllyt85bj.fsf@toots.sol>

Malte Ubl <ubl@schaffhausen.de> writes:

> What should happen in this case
> 
> my $foo = Variable->new;
> my $bar = $foo;
> 
> print $bar->name

It would be illegal. To clarify, given this "program":

        # give a description of a Person, via a Tangram schema

        my $foo = Variable->new([ref => 'Person']);
        $foo = Object->new('Person');
        $foo->{name} = 'Homer';
        $foo->{age} = 39;

I'd like it to print:

        Person* foo;
        foo = new Person;
        foo->name = "Homer";
        foo->age = 39;

Thus:
        
        my $bar = Variable->new([ref => 'Person']);
        $bar = $foo;

 ...would print:

        Person* bar;
        bar = foo;

Switching some globals would produce:

        Person foo;
        foo = new Person;
        foo.name = "Homer";
        foo.age = 39;

        Person bar;
        bar = foo;

I know that I'll have to deal with control structures somehow...
-- 
Jean-Louis Leroy
Sound Object Logic
http://www.soundobjectlogic.com


------------------------------

Date: Wed, 02 Apr 2003 14:41:00 +0200
From: Malte Ubl <ubl@schaffhausen.de>
Subject: Re: Deducing variable name during initialization
Message-Id: <b6eour$r6l$1@news.dtag.de>

Jean-Louis Leroy wrote:
> Malte Ubl <ubl@schaffhausen.de> writes:
> 
> 
>>What should happen in this case
>>
>>my $foo = Variable->new;
>>my $bar = $foo;
>>
>>print $bar->name
> 
> 
> It would be illegal. To clarify, given this "program":
> 
>         # give a description of a Person, via a Tangram schema
> 
>         my $foo = Variable->new([ref => 'Person']);
>         $foo = Object->new('Person');
>         $foo->{name} = 'Homer';
>         $foo->{age} = 39;

Could you write that as:

          my $foo : Person = Object->new('Person');
          $foo->{name} = 'Homer';
          $foo->{age} = 39;

Because then the attribute handler for Person would receive the name of 
the symbol in question.

Take a look at the module Attribute::Handlers

->malte



------------------------------

Date: Wed, 02 Apr 2003 07:54:07 -0500
From: "Susan G. Conger" <congers@yoeric.com>
Subject: Help me with a Perl Script
Message-Id: <congers-6832A1.07540702042003@news.uswest.net>

Hi,

i have been trying to figure out how to create a simple Perl script that 
has a list of files that it opens and add the following line at the top 
of the file:#if !defined (MAC_COMPILE) and an #endif as then last line 
in the file.  The file list should be hard codded at the top of the 
script.  Something like fileList=xyz.cpp,xyz2.cpp and then a for loop 
would read the string variable and do the operation on the file.  Can 
someone please help with this.

Thanks,
Susan

-- 
============================================================
Susan G. Conger       Custom Windows & Macintosh Development
President                      Web Site Design & Development
YOERIC Corporation             Database Design & Development
256 Windy Ridge Road
Chapel Hill, NC  27517
Phone/Fax: (919)542-0071
email:  congers@yoeric.com     Web:  www.yoeric.com


------------------------------

Date: Wed, 02 Apr 2003 13:01:35 GMT
From: helgi@decode.is (Helgi Briem)
Subject: Re: Help me with a Perl Script
Message-Id: <3e8adde2.374929710@news.cis.dfn.de>

On Wed, 02 Apr 2003 07:54:07 -0500, "Susan G. Conger"
<congers@yoeric.com> wrote:

Please put the subject of your question in the 
subject header.  Something like "Loop through
files and add header and footer" would  do.  Your
subject line does nothing to help those who might
search for help on this subject later.

>i have been trying to figure out how to create a simple 
>Perl script that 

Simple?  How do you know?  You have apparently
not even made an attempt to solve it, so it can't 
be that simple.

>has a list of files that it opens and add the following line at the top 
>of the file:#if !defined (MAC_COMPILE) and an #endif as then last line 
>in the file.  The file list should be hard codded at the top of the 
>script.  

perldoc -q insert 

has all the answers to your question.

>Something like fileList=xyz.cpp,xyz2.cpp 

my @filelist = qw/xyz.cpp xyz2.cpp/;
>and then a for loop 

foreach my $file (@filelist)
{
	# do something
}
>would read the string variable and do the operation on the file.  
-- 
Regards, Helgi Briem
helgi DOT briem AT decode DOT is


------------------------------

Date: Wed, 2 Apr 2003 16:18:02 +0200
From: "BSD" <bsd_devil@web.de>
Subject: Re: ICQ
Message-Id: <b6envo$458aj$1@ID-172702.news.dfncis.de>

updated my perl to perl5.6  ... it works now .
Any one here having experiences with Net::ICQ module?
I need to send System notification to my Mobile via Net::ICQ
Any input really appreciated?

BSD

"BSD" <bsd_devil@web.de> wrote in message
news:b6eesg$4f2dj$1@ID-172702.news.dfncis.de...
> cpan> install Net::ICQ
> Running install for module Net::ICQ
> Running make for J/JM/JMUHLICH/Net-ICQ-0.16.tar.gz
>   Is already unwrapped into directory /root/.cpan/build/Net-ICQ-0.16
>   Makefile.PL returned status 512
> Running make test
>   Make had some problems, maybe interrupted? Won't test
> Running make install
>   Make had some problems, maybe interrupted? Won't install
>
> BSD
>
> "Tintin" <me@privacy.net> wrote in message
> news:b6ecob$3o8gq$1@ID-172104.news.dfncis.de...
> >
> > "BSD" <bsd_devil@web.de> wrote in message
> > news:b6e9tr$4bfnq$1@ID-172702.news.dfncis.de...
> > > Did any one use perl to send SMS message via ICQ?
> > > Anay input would be really appreciated?
> >
> > http://search.cpan.org/author/JMUHLICH/Net-ICQ-0.16/lib/Net/ICQ.pm
> >
> >
>
>




------------------------------

Date: Wed, 02 Apr 2003 12:26:12 +0100
From: kz15 <nospamkz15mapson@tellabs.com>
Subject: Re: OT: Regex - hard or soft 'g'
Message-Id: <3E8AC8D4.6090601@tellabs.com>



Tassilo v. Parseval wrote:
> Also sprach Tom Beer:
> 
> 
>>How does one pronounce "regex"? Is the 'g' hard (as in "regular"), or
>>is it soft.
>>
>>I understand the etymology, but something inside me wants to make the
>>'g' soft and I was wondering what the generally accepted pronunciation
>>before I embarras myself.
> 
> 
> I am not sure whether there is one at all. Benjamin says he uses the
> soft form, whereas I always pronounced it like 'reck-ex'. To be

in case of a quick solution:                'fed-ex'
spent an hour on it, does not work:         'wreck-ex'
two hours, still does not work:             'sucks-ex'
(not to be confused with 'sux-ess' meaning the opposite)
a whole night spent on this piece of !@#$%: 'aaaargghhhh'

> absolutely sure, just pronounce it 'regular expression'...or 'pattern'. 
> ;-)
> 
> Tassilo



------------------------------

Date: Thu, 03 Apr 2003 10:49:19 +1000
From: Jussi Jumppanen <jussij@zeusedit.com>
Subject: Re: Perl editors
Message-Id: <3E8B850F.6FBA@zeusedit.com>

Stephen Adam wrote:

> I have been coding in Perl for a good few months now, though I started
> of with Delphi. The Delphi editor has facilities for break points,
> step through, high lighting of key words etc.
> 
> I know there are editors available for Perl have these functions and
> am hoping I could get some advice on which one I should use. I am
> programing under windows XP and want an editor which will be easy to
> use for a programer relatively new to Perl though I would like as much
> functionality as possible.

Take a look at the Zeus for Windows editor. 

   http://www.zeusedit.com/lookmain.html

Zeus is a powerful, highly configurable programmer's editor that 
comes pre-configured for Perl. It can also run the Perl debugger 
within the editor.

To find out how a good programmer's editor really is, see what 
some of the Zeus users have to say:

 http://www.zeusedit.com/awards.html

Jussi Jumppanen
Author of: Zeus for Windows, Win32 (Brief, Emacs, etc) FTP Text Editor
"The C/C++, Java, HTML, FTP, Python, PHP, Perl programmer's editor"
Home Page: http://www.zeusedit.com


------------------------------

Date: Wed, 02 Apr 2003 13:55:34 +0200
From: Eric Moors <scare.crow@oz.land>
Subject: regex question
Message-Id: <pan.2003.04.02.13.55.33.601418.13142@oz.land>

Hi,

I'm having a problem with a regex:

I'm trying to convert some long binary numbers

	00000100001010
into
	00-0001-0000-1010

and wrote the following program to do this:

!/usr/bin/perl -w

use strict;

my $pattern;

while (<>) {
	next unless /^\d+$/;
	$pattern = sprintf ("%032b", $_);
	while ($pattern =~ /^[01]{5,}(\.[01]{4})*$/) {
		$pattern =~ s{^([01]*)([01]{4})(\.[01]{4})*} {$1\.$2$3};
		print $pattern, "\n";
	}
}

however if I run this program, this is the output:
(Input is a 4)

Use of uninitialized value in concatenation (.) or string at ./h2b line 11, <> line 1.
0000000000000000000000000000.0100
000000000000000000000000.0000.0100
00000000000000000000.0000.0100
0000000000000000.0000.0100
000000000000.0000.0100
00000000.0000.0100
0000.0000.0100

The uninitialised variable I can understand, but why is the
string getting shorter after the first two rounds?

Eric


------------------------------

Date: 2 Apr 2003 12:08:08 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: regex question
Message-Id: <b6ejr8$fdr$2@mamenchi.zrz.TU-Berlin.DE>

Eric Moors  <scare.crow@oz.land> wrote in comp.lang.perl.misc:
> Hi,
> 
> I'm having a problem with a regex:
> 
> I'm trying to convert some long binary numbers
> 
> 	00000100001010
> into
> 	00-0001-0000-1010

That's a FAQ:  "perldoc -q 'with commas'" finds it.  Okay, you want
a "-" instead of a ",", but that's the whole difference.

Anno
-- 
-- 

sub nmax { @$_[ @_] = (); $#$_ }


------------------------------

Date: Wed, 02 Apr 2003 14:14:07 +0200
From: Eric Moors <scare.crow@oz.land>
Subject: Re: regex question
Message-Id: <pan.2003.04.02.14.14.06.585886.13142@oz.land>

On Wed, 02 Apr 2003 14:08:08 +0200, Anno Siegel wrote:

> Eric Moors  <scare.crow@oz.land> wrote in comp.lang.perl.misc:
>> Hi,
>> 
>> I'm having a problem with a regex:
>> 
>> I'm trying to convert some long binary numbers
>> 
>> 	00000100001010
>> into
>> 	00-0001-0000-1010
> 
> That's a FAQ:  "perldoc -q 'with commas'" finds it.  Okay, you want a
> "-" instead of a ",", but that's the whole difference.
> 

Thanks.
searching a FAQ isn't easy if you don't know what to look for.

Eric


------------------------------

Date: Wed, 02 Apr 2003 14:18:28 +0200
From: "Tore Aursand" <tore@aursand.no>
Subject: Re: regex question
Message-Id: <pan.2003.04.02.12.15.34.105200@aursand.no>

On Wed, 02 Apr 2003 13:55:34 +0200, Eric Moors wrote:
> Subject: regex question

Please put the subject of your posting in the Subject field.

> I'm trying to convert some long binary numbers
> 
> 	00000100001010
> into
> 	00-0001-0000-1010

I prefer doing this when I want to format long numbers (ie. formatting
123456789 into 123,456,789);

  1 while $string =~ s/^(\d+)(\d{4})/$1-$2/;

I modified the regular expression above so that it should work with your
data.


-- 
Tore Aursand <tore@aursand.no>

"You know the world is going crazy when the best rapper is white, the best
 golfer is black, France is accusing US of arrogance and Germany doesn't
 want to go to war."


------------------------------

Date: 2 Apr 2003 12:30:51 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: regex question
Message-Id: <b6el5r$fdr$3@mamenchi.zrz.TU-Berlin.DE>

Tore Aursand <tore@aursand.no> wrote in comp.lang.perl.misc:
> On Wed, 02 Apr 2003 13:55:34 +0200, Eric Moors wrote:
> > Subject: regex question
> 
> Please put the subject of your posting in the Subject field.
> 
> > I'm trying to convert some long binary numbers
> > 
> > 	00000100001010
> > into
> > 	00-0001-0000-1010
> 
> I prefer doing this when I want to format long numbers (ie. formatting
> 123456789 into 123,456,789);
> 
>   1 while $string =~ s/^(\d+)(\d{4})/$1-$2/;
> 
> I modified the regular expression above so that it should work with your
> data.

Ah, that's a nice one.  As the FAQ shows, it can be done in a single
regex, but your's is much easier on the eyes.

Anno
-- 
-- 

sub nmax { @$_[ @_] = (); $#$_ }


------------------------------

Date: Wed, 02 Apr 2003 14:48:44 +0200
From: Eric Moors <scare.crow@oz.land>
Subject: Re: regex question
Message-Id: <pan.2003.04.02.14.48.44.27378.13142@oz.land>

On Wed, 02 Apr 2003 14:18:28 +0200, Tore Aursand wrote:

> On Wed, 02 Apr 2003 13:55:34 +0200, Eric Moors wrote:
>> Subject: regex question
> 
> Please put the subject of your posting in the Subject field.

Ehmm...
I thought I did just that.
What's wrong with it?

Eric


------------------------------

Date: 2 Apr 2003 11:49:02 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: search and replace long hex string
Message-Id: <b6eine$fdr$1@mamenchi.zrz.TU-Berlin.DE>

Doug Kite  <dougkite@yahoo.com> wrote in comp.lang.perl.misc:
> John W. Krahn wrote:
> >>I could not get any of these to work. Only the single byte hex replace
> >>will work.  Any other ideas?
> > 
> > 
> > It could be that you have an older version of Perl that doesn't
> > understand (?<=) and (?=).
> > 
> > perl -i -pe 's{(\xb3\x01\x00\x16)\x24(\xf0)}{$1\x14$2}g' /foo/bar
> 
> 
> I'm running 5.8.0. Unfortunately the above example wouldn't work either. 

Your pattern contains a "$" (0x24) which must be escaped.  Try

    s{\Q(\xb3\x01\x00\x16)\x24(\xf0)}{$1\x14$2}g

Anno
-- 
-- 

sub nmax { @$_[ @_] = (); $#$_ }


------------------------------

Date: 2 Apr 2003 03:32:45 -0800
From: mfb@gmx.net (Michael Bickel)
Subject: Re: slow file access under windows
Message-Id: <7e748eaa.0304020332.5d5ba32a@posting.google.com>

Benjamin Goldberg <goldbb2@earthlink.net> wrote in message news:<3E89D3F2.4EC8FA3F@earthlink.net>...
> Michael Bickel wrote:
> > 
> > Benjamin Goldberg <goldbb2@earthlink.net> wrote in message news:<3E88FA4B.7C1784F6@earthlink.net>...
> > > Michael Bickel wrote:
> > > >
> > > > Hi,
> > > > I recognice, that a simple file access is much slower under Windows
> > > > (W2K, Perl 5.6.1) than under Unix (AIX). I just check 5 directories if
> > > > they exist or not  (with switch and opendir) and it took more than 10
> > > > sec.
> > > > Also using File::Find (see below) take much longer under Win than
> > > > under AIX (Win: 25 sec., AIX <2 sec).
> > > > Has anyone suggestions to increase the speed?
> > >
> > > Windows and Unix use different filesystems.  The filesystem which
> > > Windows uses is slower than the filesystem which Unix uses.  This is not
> > > perl's fault, and there is no perl solution.
> > 
> > But even the KShell from AT&T is faster:
> > find with KSH:        2s
> > File::Find with Perl: 20s
> > (Directory contains 570 Files)
> > 
> > Isn't this difference to big?
> 
> The "find" program that you're running under ksh is a C executable,
> specially designed for the purpose of doing directory traversal, so
> of course it's faster than a perl version of the same.
> 
> (ksh is irrelevant, since it's "find" that's doing all the work.)
> 
> Do a test finding out the speeds of "find" on unix and on windows,
> and the speeds of "File::Find" on unix on windows.
> 
> For File::Find, it will run X times faster on unix than windows.
> For find, it will run Y times faster on unix than windows.
> 
> On unix, find will be Z times faster than File::Find.
> On windows, find will be W times faster than File::Find.
> 
> If X and Y differ significantly, or if Z and W differ significantly,
> *then* you might have a significant concern.

Ok, lets see:

a = find on win
b = find on unix
c = File::Find on win
d = File::Find on unix
X = c/d
Y = a/b
Z = d/b
W = c/a

Directory with 570 Files:
a = 1s
b = <1s
c = 20s
d = <1s
X = >20
Y = >1
W = 20
Z = 1
X ~ Y ?: 20 !~  1
Z ~ W ?:  1 !~ 20

Everything but File::Find on win is acceptable. When File::Find is
running, it prints out some line, then stopp a short time before he
continues, and so on. What's the reason for this behavior? Is this the
Filesystem or another bottleneck?


------------------------------

Date: Wed, 02 Apr 2003 12:52:07 GMT
From: "joe" <tunmaster@hotmail.com>
Subject: strict, global vars and 'require'
Message-Id: <X1Bia.1417746$Wr.52882535@Flipper>

LS,

I'd be so grateful if anyone could tell me how to solve my problem. It's
like this...

Just recently I started writing my scripts using the correct codes, that is
I use the 'strict' function. This function requires a variable to be
declared using 'my varName'. But when I import a script via 'require
plop.cgi', this script doesn't see the vars declared in the main script!

I've tried to use packages, but this won't do the the trick for me. Can
anone help me out here...?!?

TIA,

Joe




------------------------------

Date: 2 Apr 2003 05:26:53 -0800
From: genericax@hotmail.com (Sara)
Subject: Re: That's just plain WRONG
Message-Id: <776e0325.0304020526.59712556@posting.google.com>

Ethan Brown <ethan@draupnir.gso.saic.com> wrote in message news:<vrbrzqj5f3.fsf@draupnir.gso.saic.com>...
> Haiku
> 
> Perl knowledge I sought
> At the font that is C'PAN.
> Sadness.  It's Matt's Scripts.
> 
> --Ethan Brown
> --Keyboards: "The Fabulous Pelicans" (www.pelicans.com)
> --In a band?  Use http://www.WheresTheGig.com for free.

Ahh the venerable Haiku- Well done!


Gx


------------------------------

Date: Wed, 02 Apr 2003 14:00:00 GMT
From: peter@PSDT.com (Peter Scott)
Subject: Re: Two perl-debugging question
Message-Id: <A1Cia.361689$na.28014358@news2.calgary.shaw.ca>

In article <a657ec02.0304012329.20a8a80f@posting.google.com>,
 i5513@hotmail.com (i5513) writes:
>Hi! I want to use perl' debugger. How can I enable a breakpoint at
>other file that isn't principal?
>
>I'm look for a sentence like:
>
>b my_file#no_lin
>
>(by default it is only possible at current file, isn't?)
>
>I know I can : 
>b postpone my_subr
>It is the more similar I could find, but I would like go to a line at
>this routine directly, without two break points.

You can use the f command to switch to the other source file and then
the b command to set a breakpoint at a line.  The other file must have
been loaded already.  If it hasn't, you'll have to go first to a point
where it has been loaded.

>What does 'Breakpoints may only be set on lines that begin an
>executable statement' is mean?
>
>I don't understand why some times I recived a message that says me
>"Line x not breakable".

You can't set a breakpoint at a line of code if there's no code there.
Do a source listing in the debugger with l or w and you'll see a :
printed next to the line numbers of executable lines.

-- 
Peter Scott
http://www.perldebugged.com


------------------------------

Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>


Administrivia:

The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc.  For subscription or unsubscription requests, send
the single line:

	subscribe perl-users
or:
	unsubscribe perl-users

to almanac@ruby.oce.orst.edu.  

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.

For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V10 Issue 4805
***************************************


home help back first fref pref prev next nref lref last post