[29052] in Perl-Users-Digest
Perl-Users Digest, Issue: 296 Volume: 11
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Apr 3 16:11:05 2007
Date: Tue, 3 Apr 2007 13:09:21 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Tue, 3 Apr 2007 Volume: 11 Number: 296
Today's topics:
Re: Any "consumer review generators" available? <null@null.null>
Re: Any good Perl coders out there? <bik.mido@tiscalinet.it>
Re: Any good Perl coders out there? <wahab-mail@gmx.de>
Re: Catching print errors <hjp-usenet2@hjp.at>
Re: comp.lang.perl.cgi? <scobloke2@infotop.co.uk>
Re: comp.lang.perl.cgi? <sisyphus1@nomail.afraid.org>
Re: comp.lang.perl.cgi? <bik.mido@tiscalinet.it>
Re: comp.lang.perl.cgi? (Randal L. Schwartz)
Re: comp.lang.perl.cgi? <spamtrap@dot-app.org>
Re: comp.lang.perl.cgi? <spamtrap@dot-app.org>
Re: comp.lang.perl.cgi? <noreply@gunnar.cc>
Re: comp.lang.perl.cgi? xhoster@gmail.com
deleting from stash <bik.mido@tiscalinet.it>
Re: deleting from stash <rs@474.at>
Re: deleting from stash <bik.mido@tiscalinet.it>
Re: deleting from stash <rs@474.at>
Error when using a defining a new module <ashwanijain@gmail.com>
Re: Error when using a defining a new module <sisyphus1@nomail.afraid.org>
Re: Error when using a defining a new module (Jamie)
extending a module? <bugbear@trim_papermule.co.uk_trim>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Tue, 03 Apr 2007 09:53:35 GMT
From: nullified <null@null.null>
Subject: Re: Any "consumer review generators" available?
Message-Id: <hv8413tqcb8459durhsi3ro13eg8vr714k@4ax.com>
On Fri, 30 Mar 2007 22:15:20 +0200, Schraalhans Keukenmeester
<bitbucket@invalid.spam> wrote:
>nullified wrote:
>> On 30 Mar 2007 07:01:16 -0700, "Evil Otto" <zburnham@gmail.com> wrote:
>>
>>> On Mar 30, 3:46 am, nullified <n...@null.null> wrote:
>>>> On 29 Mar 2007 20:34:26 -0700, "Evil Otto" <zburn...@gmail.com> wrote:
>>>>
>>>>> On Mar 29, 2:19 pm, aral...@aol.com wrote:
>>>>>> I am looking for a fake consumer review generator that could generate realistic looking reviews for any products, kind of like on amazon.com but generated by Artificial Intelligence. Is there a package available in your favorite programing language... thx alan
>>>>> I really, really hope that you're looking to generate test data or
>>>>> filler text.
>>>>> If you're not, then DIAF.
>>>> Die In A Fire? Drop In A Fryer? Doug Is A Fucker? Drown In A Fart?
>>> Any of those would accurately describe the underlying sentiment, but I
>>> had "Die In A Fire" in mind specifically.
>>
>> FM!, IWRFT!
>Perhaps if he finds his miracle script he can also train it to create
>and 'solve' funny acronyms?
Sorry. That was "Fuck Me! I Was Right First Time!"
------------------------------
Date: Tue, 03 Apr 2007 10:17:17 +0200
From: Michele Dondi <bik.mido@tiscalinet.it>
Subject: Re: Any good Perl coders out there?
Message-Id: <tb3413le38cafuf328ag0qd6f58inid8cr@4ax.com>
On Tue, 03 Apr 2007 00:27:29 GMT, nospam@geniegate.com (Jamie) wrote:
>IRC in general doesn't count, I pretty much wrote it off. Though, if I were
>to actually consider it, I'd have to say it's about as bad. (and actually,
>being fair, some of the #linux channels I've seen are a /LOT/ worse than
>anything perl related on the rude-meter)
>
>Of course, these days, everyone has "upgraded" to the newer and superior
>closed, commercial systems of Yahoo! and MSN.
Jabber.
Michele
--
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
.'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,
------------------------------
Date: Tue, 03 Apr 2007 17:57:54 +0200
From: Mirco Wahab <wahab-mail@gmx.de>
Subject: Re: Any good Perl coders out there?
Message-Id: <euttt5$3ao$1@mlucom4.urz.uni-halle.de>
Jamie wrote:
> One thing I've run into with some people is that perl is "old" php is "new"
> and the thing to do is "upgrade" to PHP. Newer is better. (regardless of
> whether or not it actually is)
I really use PHP more or less on a daily base,
so I think I can somehow 'assess' its value. It
is, without any doubt, much easier to get something
working (hacked together) by people which are basically
'cheaper' (than others).
<index finger>
The best Samurai group will get badly beaten up
in the end by a huge bulk of Musket bearer not
even requiring an education longer than one day ;-)
</index finger>
This is how things work, imho. Cost decides at last.
Regards
M.
------------------------------
Date: Tue, 3 Apr 2007 09:47:13 +0200
From: "Peter J. Holzer" <hjp-usenet2@hjp.at>
Subject: Re: Catching print errors
Message-Id: <slrnf141k1.p0k.hjp-usenet2@yoyo.hjp.at>
On 2007-04-03 00:03, Jamie <nospam@geniegate.com> wrote:
> In <slrnf11pqs.q5a.hjp-usenet2@yoyo.hjp.at>,
> "Peter J. Holzer" <hjp-usenet2@hjp.at> mentions:
>>Note that in these examples I didn't actually test for the reason of the
>>failure. The disk might be full, or the user may have exceeded his
>>quota, or there might be an I/O error on the disk, etc. It doesn't
>>matter for the program, because in any case it cannot continue. It may
>>matter for the user, because he needs to do different things to remedy
>>the problem before starting the program again.
>
> Thats true, but, in drastic measures like that, *usually* (as in, all the
> cases I've seen so far) other tools will tell them something is wrong.)
Maybe, maybe not. If you have one cronjob which creates huge temporary
files and overruns the quota there is a good chance that this goes
undetected if the job doesn't itself complain.
Disk full and I/O errors are usually written to the syslog and a
monitoring tool might pick them up from there, but you still don't know
if this resulted in data corruption and which files were affected.
hp
--
_ | Peter J. Holzer | Blaming Perl for the inability of programmers
|_|_) | Sysadmin WSR | to write clearly is like blaming English for
| | | hjp@hjp.at | the circumlocutions of bureaucrats.
__/ | http://www.hjp.at/ | -- Charlton Wilbur in clpm
------------------------------
Date: Tue, 03 Apr 2007 10:11:38 +0100
From: Ian Wilson <scobloke2@infotop.co.uk>
Subject: Re: comp.lang.perl.cgi?
Message-Id: <46121a4e$0$21838$db0fefd9@news.zen.co.uk>
Sherm Pendley wrote:
> Gunnar Hjalmarsson <noreply@gunnar.cc> writes:
>
>
>> The group comp.infosystems.www.authoring.cgi has been down for
>> several months. As far as I can understand, it means that there is
>> no longer an appropriate Usenet group for those who use Perl for
>> web applications to discuss CGI and HTTP matters.
>
>
> comp.infosystems.www.authoring.cgi
>
Which apparently is moderated by a robot owned by Thomas Boutell, said
robot appears to be asleep.
My ISP doesnt carry comp.infosystems.www.authoring.cgi.
Just my $0.02 worth.
------------------------------
Date: Tue, 3 Apr 2007 23:08:14 +1000
From: "Sisyphus" <sisyphus1@nomail.afraid.org>
Subject: Re: comp.lang.perl.cgi?
Message-Id: <461251be$0$5748$afc38c87@news.optusnet.com.au>
"Gunnar Hjalmarsson" <noreply@gunnar.cc> wrote in message
news:57eq3cF2btrleU1@mid.individual.net...
.
.
> Would you mind to share your thinking on the subject, Tad?
Yes, I'm also interested to hear Tad's thinking on this.
For as long as I've been using perl, it has been the case that one sends
one's perl questions to comp.lang.perl.misc, and one's cgi questions go to
comp.infosystems.www.authoring.cgi. It's a long time since I've subscribed
to the latter and I'm amazed to hear that it has been out of service for a
lengthy period of time.
For mine, the best solution would be to resurrect
comp.infosystems.www.authoring.cgi. (I have no idea whether that's a
practical solution :-)
Cheers,
Rob
------------------------------
Date: Tue, 03 Apr 2007 15:59:38 +0200
From: Michele Dondi <bik.mido@tiscalinet.it>
Subject: Re: comp.lang.perl.cgi?
Message-Id: <j7n413puobnblefp0juacfb0jt08bq4ll9@4ax.com>
On Tue, 03 Apr 2007 12:52:24 +0200, Gunnar Hjalmarsson
<noreply@gunnar.cc> wrote:
>Would you mind to share your thinking on the subject, Tad? Do you
>welcome those who use Perl for webb stuff to use clpmisc for other
>matters than pure Perl programming ditto, or do you find it satisfying
>that there is no appropriate Usenet group for them?
Don't know 'bout Tad, but personally I welcome to clpmisc anyone for
any ("misc") use of Perl, web stuff included. Since I don't know much
in that area, it gives me chances of learning something. I don't
welcome any question that has really *nothing* to do with Perl.
Simple, isn't it?
Michele
--
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
.'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,
------------------------------
Date: Tue, 03 Apr 2007 08:04:24 -0700
From: merlyn@stonehenge.com (Randal L. Schwartz)
Subject: Re: comp.lang.perl.cgi?
Message-Id: <86bqi5ebyf.fsf@blue.stonehenge.com>
>>>>> "Sisyphus" == Sisyphus <sisyphus1@nomail.afraid.org> writes:
Sisyphus> For mine, the best solution would be to resurrect
Sisyphus> comp.infosystems.www.authoring.cgi. (I have no idea whether that's a
Sisyphus> practical solution :-)
I'm working on that right now. The group's been dead since oct 2006, and
something is broken in the chain from posting to the
self-moderated-bot-approval to injecting back into the news system. I'm in
touch with the bot operator and we'll have some solution shortly.
print "Just another Perl hacker,"; # and clpa moderator
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!
--
Posted via a free Usenet account from http://www.teranews.com
------------------------------
Date: Tue, 03 Apr 2007 11:50:09 -0400
From: Sherm Pendley <spamtrap@dot-app.org>
Subject: Re: comp.lang.perl.cgi?
Message-Id: <m2fy7hpidq.fsf@local.wv-www.com>
Gunnar Hjalmarsson <noreply@gunnar.cc> writes:
> Tad McClellan wrote:
>>>>>>>>>"GH" == Gunnar Hjalmarsson <noreply@gunnar.cc> writes:
>>>>
>>>> GH> Maybe it's time to establish the group comp.lang.perl.cgi?
>>
>> I would vote no.
>
> Would you mind to share your thinking on the subject, Tad? Do you
> welcome those who use Perl for webb stuff to use clpmisc for other
> matters than pure Perl programming ditto, or do you find it satisfying
> that there is no appropriate Usenet group for them?
That's a false dichotomy; other possibilities exist.
Speaking for myself (not Tad), my objection to it is this: We've already
had c.i.w.a.cgi and www.authoring.cgi for some time now. The problem with
offtopic questions being posted here has nothing to do with there being no
appropriate forum - there is (or was) such fora, and finding them was no
more nor less difficult than finding this one.
Offtopic questions tend to be posted here because the poster is unable to
correctly partition the problem space. Creating a new group won't solve
that problem; it'll simply be ignored like the others were.
sherm--
--
Web Hosting by West Virginians, for West Virginians: http://wv-www.net
Cocoa programming in Perl: http://camelbones.sourceforge.net
------------------------------
Date: Tue, 03 Apr 2007 12:04:12 -0400
From: Sherm Pendley <spamtrap@dot-app.org>
Subject: Re: comp.lang.perl.cgi?
Message-Id: <m2bqi5phqb.fsf@local.wv-www.com>
Michele Dondi <bik.mido@tiscalinet.it> writes:
> On Tue, 03 Apr 2007 12:52:24 +0200, Gunnar Hjalmarsson
> <noreply@gunnar.cc> wrote:
>
>>Would you mind to share your thinking on the subject, Tad? Do you
>>welcome those who use Perl for webb stuff to use clpmisc for other
>>matters than pure Perl programming ditto, or do you find it satisfying
>>that there is no appropriate Usenet group for them?
>
> Don't know 'bout Tad, but personally I welcome to clpmisc anyone for
> any ("misc") use of Perl, web stuff included.
I think a lot of us feel the same way; I have no objections to questions
that are actually about Perl, regardless of what the code in question is
being used for.
> in that area, it gives me chances of learning something. I don't
> welcome any question that has really *nothing* to do with Perl.
Exactly so. The problem is quite a few questions get posted here that are
really HTML or HTTP questions, where the fact that a Perl script happens
to be involved simply isn't relevant to the question.
> Simple, isn't it?
To an experienced developer it is.
On the other hand, the volume of off-topic posts here suggests that parti-
tioning the problem space is a difficult concept for novices to master. I
can't imagine how creating a new group would change that.
sherm--
--
Web Hosting by West Virginians, for West Virginians: http://wv-www.net
Cocoa programming in Perl: http://camelbones.sourceforge.net
------------------------------
Date: Tue, 03 Apr 2007 18:23:57 +0200
From: Gunnar Hjalmarsson <noreply@gunnar.cc>
Subject: Re: comp.lang.perl.cgi?
Message-Id: <57fdh1F2cobkeU1@mid.individual.net>
Sherm Pendley wrote:
> the volume of off-topic posts here suggests that parti-
> tioning the problem space is a difficult concept for novices to master. I
> can't imagine how creating a new group would change that.
It wouldn't, but my idea with a group called clpwww was that its charter
would be more permissive, just like ciwac was.
Now, since ciwac is being fixed, there is no reason to keep discussing a
new comp.lang.perl group. That was good news, Randal!
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
------------------------------
Date: 03 Apr 2007 16:34:36 GMT
From: xhoster@gmail.com
Subject: Re: comp.lang.perl.cgi?
Message-Id: <20070403123438.360$GP@newsreader.com>
Ian Wilson <scobloke2@infotop.co.uk> wrote:
> Sherm Pendley wrote:
> > Gunnar Hjalmarsson <noreply@gunnar.cc> writes:
> >
> >
> >> The group comp.infosystems.www.authoring.cgi has been down for
> >> several months. As far as I can understand, it means that there is
> >> no longer an appropriate Usenet group for those who use Perl for
> >> web applications to discuss CGI and HTTP matters.
> >
> >
> > comp.infosystems.www.authoring.cgi
> >
>
> Which apparently is moderated by a robot owned by Thomas Boutell, said
> robot appears to be asleep.
I would support either changing moderators, or changing the group
to unmoderated, and would oppose just creating a new group in lieu of doing
either one of those.
Xho
--
-------------------- http://NewsReader.Com/ --------------------
Usenet Newsgroup Service $9.95/Month 30GB
------------------------------
Date: Tue, 03 Apr 2007 15:44:28 +0200
From: Michele Dondi <bik.mido@tiscalinet.it>
Subject: deleting from stash
Message-Id: <lgl4135mr84j18empbmt5fvserpfvatbh2@4ax.com>
Just learnt in use Perl, <http://tinyurl.com/2g77lv>:
: Replace delete by undef in your example, and it works. You can't
: delete subs from a stash in Perl 5.8, only undef them. If you use
: delete, the sub still exists (you can use "exists &foo" to test for
: it). That can be considered as a bug.
(Rafael Garcia-Suarez)
Well, many people here supposedly already knew. It was news to me. Or
if I knew, I forgot. You don't do stash manipulation everyday, after
all.
Michele
--
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
.'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,
------------------------------
Date: Tue, 03 Apr 2007 19:06:18 +0200
From: Robert 'phaylon' Sedlacek <rs@474.at>
Subject: Re: deleting from stash
Message-Id: <461289a4$0$20286$9b4e6d93@newsspool3.arcor-online.net>
Michele Dondi wrote:
> Just learnt in use Perl, <http://tinyurl.com/2g77lv>:
>
> : Replace delete by undef in your example, and it works. You can't
> : delete subs from a stash in Perl 5.8, only undef them. If you use
> : delete, the sub still exists (you can use "exists &foo" to test for
> : it). That can be considered as a bug.
> (Rafael Garcia-Suarez)
>
> Well, many people here supposedly already knew. It was news to me. Or
> if I knew, I forgot. You don't do stash manipulation everyday, after
> all.
Thankfully (for me) the behaviour that allows namespace::clean to work
is now also "stabilised" by a test in blead.
.phaylon
------------------------------
Date: Tue, 03 Apr 2007 20:02:04 +0200
From: Michele Dondi <bik.mido@tiscalinet.it>
Subject: Re: deleting from stash
Message-Id: <dj5513pm87nm3tnmtnd9l07lkblmnndumh@4ax.com>
On Tue, 03 Apr 2007 19:06:18 +0200, Robert 'phaylon' Sedlacek
<rs@474.at> wrote:
>> Just learnt in use Perl, <http://tinyurl.com/2g77lv>:
>>
>> : Replace delete by undef in your example, and it works. You can't
>> : delete subs from a stash in Perl 5.8, only undef them. If you use
>> : delete, the sub still exists (you can use "exists &foo" to test for
>> : it). That can be considered as a bug.
>> (Rafael Garcia-Suarez)
>>
>> Well, many people here supposedly already knew. It was news to me. Or
>> if I knew, I forgot. You don't do stash manipulation everyday, after
>> all.
>
>Thankfully (for me) the behaviour that allows namespace::clean to work
>is now also "stabilised" by a test in blead.
Really? Well, I'm happy for you. Anyway, it's thanks to the smurfs,
that I got to know this, you know! ;-)
Michele
--
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
.'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,
------------------------------
Date: Tue, 03 Apr 2007 21:46:52 +0200
From: Robert 'phaylon' Sedlacek <rs@474.at>
Subject: Re: deleting from stash
Message-Id: <4612af45$0$6402$9b4e6d93@newsspool2.arcor-online.net>
Michele Dondi wrote:
> Really? Well, I'm happy for you. Anyway, it's thanks to the smurfs,
> that I got to know this, you know! ;-)
Oh yeah, those thingies always save the day ;)
.phaylon
------------------------------
Date: 3 Apr 2007 05:25:42 -0700
From: "ashwani" <ashwanijain@gmail.com>
Subject: Error when using a defining a new module
Message-Id: <1175603142.661762.188790@n59g2000hsh.googlegroups.com>
Hi
i am writting a new module service_ini.
here is the code which is using the module:
#!/usr/bin/perl
#use strict;
use warnings;
BEGIN {
push @INC, 'D:/Strech Goals/Unit test Automation/Development/
service_ini/lib';
}
use service_ini;
my %this = (SERVICE_INI_FILE_NAME => "sgutat.ini");
$this{'TRACE_FILE_NAME'} = "D:/Strech Goals/Unit test Automation/
Development/input files/OC_CC_C2_002.tra";
$this->{'SERVICE_INI_FD'} = service_ini::openServiceIni();
$this->{'SERVICE_INI_PARAM'} = service_ini::ReadServiceINIParam($this-
>{'SERVICE_INI_FD'});
open(TraFD,$this->{'TRACE_FILE_NAME'}) || die "Can't open file $this-
>{'TRACE_FILE_NAME'}" ;
print "\n$this->{'TRACE_FILE_NAME'} has opened";
while(my $line = <TraFD>)
{
chomp($line);
if ($line =~ m/(State)(\[[0-9]+\]) ([0-9]+), SIB:((\w+\/\w+)((\/\w
+)*))/)
{
print "\nLine = $line";
print "\nState No: $3";
print "\nSIB Name: $4\n";
}
}#end of while
print "\nclosing $this->{'TRACE_FILE_NAME'}";
close(TraFD)|| die "Can't close file: $this->{'TRACE_FILE_NAME'}";
and code of service_ini module is
______________________________________________________
package service_ini;
#require Exporter;
#use AutoLoader qw(AUTOLOAD);
#our @ISA = qw(Exporter);
# Items to export into callers namespace by default. Note: do not
export
# names by default without a very good reason. Use EXPORT_OK instead.
# Do not simply export all your public functions/methods/constants.
# This allows declaration use service_ini ':all';
# If you do not need this, moving things directly into @EXPORT or
@EXPORT_OK
# will save memory.
#our %EXPORT_TAGS = ( 'all' => [ qw(
#) ] );
#our @EXPORT_OK = ( @{ $EXPORT_TAGS{'all'} } );
#our @EXPORT = qw(
#);
#our $VERSION = '0.01';
# Preloaded methods go here.
# Autoload methods go after =cut, and are processed by the autosplit
program.
#1;
#__END__
# Below is stub documentation for your module. You'd better edit it!
=head1 NAME
service_ini - Perl extension for blah blah blah
=head1 SYNOPSIS
use service_ini;
blah blah blah
=head1 DESCRIPTION
Stub documentation for service_ini, created by h2xs. It looks like the
author of the extension was negligent enough to leave the stub
unedited.
Blah blah blah.
=head2 EXPORT
None by default.
=head1 SEE ALSO
Mention other useful documentation such as the documentation of
related modules or operating system documentation (such as man pages
in UNIX), or any relevant external documentation such as RFCs or
standards.
If you have a mailing list set up for your module, mention it here.
If you have a web site set up for your module, mention it here.
=head1 AUTHOR
A. U. Thor, E<lt>a.u.thor@a.galaxy.far.far.awayE<gt>
=head1 COPYRIGHT AND LICENSE
Copyright (C) 2007 by A. U. Thor
This library is free software; you can redistribute it and/or modify
it under the same terms as Perl itself, either Perl version 5.8.6 or,
at your option, any later version of Perl 5 you may have available.
=cut
use 5.008006;
use strict;
use warnings;
my $service_ini_file_name = 'sgutat.ini'
#sub new {
#return $this;
#}
sub openServiceIni {
print "\nEntry in service_ini::openServiceIn";
my $FD=undef;
open($FD,$service_ini_file_name) || die "\ncan not open
configuration file $service_ini_file_name\n";
print "\nExit from service_ini::openServiceIni";
return $FD;
}
sub ReadServiceINIParam
{
print "\nEntry in service_ini::ReadServiceINIParam";
#my $FH = undef;
#open($FH,$service_ini_file_name) || die "\ncan not open
configuration file $service_ini_file_name\n";
print "\nExit from service_ini::ReadServiceINIParam";
}#end of ReadServiceINIParam
1;
______________________________________________________
but when i am compiling this it is giving error as
syntax error at D:/Strech Goals/Unit test Automation/Development/
service_ini/lib/service_ini.pm line 97, near "sub openServiceIni "
syntax error at D:/Strech Goals/Unit test Automation/Development/
service_ini/lib/service_ini.pm line 103, near "}"
Compilation failed in require at Main.pl line 9.
BEGIN failed--compilation aborted at Main.pl line 9.
------------------------------
Date: Tue, 3 Apr 2007 22:59:23 +1000
From: "Sisyphus" <sisyphus1@nomail.afraid.org>
Subject: Re: Error when using a defining a new module
Message-Id: <46124faa$0$16553$afc38c87@news.optusnet.com.au>
"ashwani" <ashwanijain@gmail.com> wrote in message
news:1175603142.661762.188790@n59g2000hsh.googlegroups.com...
.
.
> my $service_ini_file_name = 'sgutat.ini'
A missing ';' perhaps ?
Cheers,
Rob
------------------------------
Date: Tue, 03 Apr 2007 13:04:55 GMT
From: nospam@geniegate.com (Jamie)
Subject: Re: Error when using a defining a new module
Message-Id: <Lc117558517511110x88e2e14@pong.podro.com>
In <1175603142.661762.188790@n59g2000hsh.googlegroups.com>,
"ashwani" <ashwanijain@gmail.com> mentions:
[snip]
>use 5.008006;
>use strict;
>use warnings;
>
>my $service_ini_file_name = 'sgutat.ini'
^^ I think you need a ";"
>#sub new {
>
> #return $this;
>#}
>sub openServiceIni {
> print "\nEntry in service_ini::openServiceIn";
> my $FD=undef;
> open($FD,$service_ini_file_name) || die "\ncan not open
>configuration file $service_ini_file_name\n";
> print "\nExit from service_ini::openServiceIni";
> return $FD;
>}
[snip]
>but when i am compiling this it is giving error as
>syntax error at D:/Strech Goals/Unit test Automation/Development/
>service_ini/lib/service_ini.pm line 97, near "sub openServiceIni "
>syntax error at D:/Strech Goals/Unit test Automation/Development/
>service_ini/lib/service_ini.pm line 103, near "}"
>Compilation failed in require at Main.pl line 9.
>BEGIN failed--compilation aborted at Main.pl line 9.
You might consider naming it in CamelCaps, as lowercase package
names are generally a language pragma. (like strict.pm for example)
Should be harmless in your case, just a suggestion.
Syntax errors like that are kinda tricky to catch, the error
is sometimes long gone before the perl parser figures out all
is not well in the camp.
If word-wrap/tabs screwed this up, I meant a semicolon after
sgutat.ini
my $service_ini_file_name = 'sgutat.ini';
Jamie
--
http://www.geniegate.com Custom web programming
Perl * Java * UNIX User Management Solutions
------------------------------
Date: Tue, 03 Apr 2007 16:18:29 +0100
From: bugbear <bugbear@trim_papermule.co.uk_trim>
Subject: extending a module?
Message-Id: <46127046$0$8739$ed2619ec@ptn-nntp-reader02.plus.net>
For local convenience I would like to "wrap"
an existing module, making a new and slightly
larger/customised module.
Is there a convention on doing this?
Export and @ISA would seem quite key :-)
Specifically, can I (somehow)
manufacture the new Modules @EXPORT and
@EXPORT_OK from the underlying module?
What about exported variables in the
underlying module?
(as you may all have gathered I'm trying to tidy
up, refactor, debug, a large morass
of legacy code)
BugBear
------------------------------
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.
NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice.
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 V11 Issue 296
**************************************