Re: Importing subs + strict and warnings using Exporter

2014-03-31 Thread Octavian Rasnita
From: "Ruud H.G. van Tol" > On 2014-03-30 19:10, Octavian Rasnita wrote: >> From: "Dr.Ruud" >> >>> On 2014-03-30 12:26, Octavian Rasnita wrote: >>> >>>> But I also want that module to export strict and warnings. >>> >

Re: Importing subs + strict and warnings using Exporter

2014-03-30 Thread Ruud H.G. van Tol
On 2014-03-30 19:10, Octavian Rasnita wrote: From: "Dr.Ruud" On 2014-03-30 12:26, Octavian Rasnita wrote: But I also want that module to export strict and warnings. http://search.cpan.org/perldoc?Modern%3A%3APerl Thanks. I know about it but it is not helpful. How unimaginati

Re: Importing subs + strict and warnings using Exporter

2014-03-30 Thread Octavian Rasnita
From: "Dr.Ruud" On 2014-03-30 12:26, Octavian Rasnita wrote: But I also want that module to export strict and warnings. http://search.cpan.org/perldoc?Modern%3A%3APerl -- Ruud Thanks. I know about it but it is not helpful. I want to use in my scripts just: use MyModule;

Re: Importing subs + strict and warnings using Exporter

2014-03-30 Thread Dr.Ruud
On 2014-03-30 12:26, Octavian Rasnita wrote: But I also want that module to export strict and warnings. http://search.cpan.org/perldoc?Modern%3A%3APerl -- Ruud -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http

Importing subs + strict and warnings using Exporter

2014-03-30 Thread Octavian Rasnita
Hello, I am trying to create a module that exports a few subroutines in the script that uses it. This is OK, very simple to do using Exporter. But I also want that module to export strict and warnings. If I don't use Exporter in the module, I can make it to export strict and warnings,

RE: variable definition error not caught when using strict and warnings

2012-11-09 Thread Nemana, Satya
From: Rob Dixon [rob.di...@gmx.com] Sent: 09 November 2012 17:17 To: beginners@perl.org Cc: Nemana, Satya Subject: Re: variable definition error not caught when using strict and warnings On 09/11/2012 17:08, Nemana, Satya wrote: > Hi > > I am

Re: variable definition error not caught when using strict and warnings

2012-11-09 Thread Rob Dixon
On 09/11/2012 17:08, Nemana, Satya wrote: Hi I am a little confused with this program Program: use strict; use warnings; if ($999 == 1056) { print ("\nequal"); } else { print ("\nnot equal"); } What I expect: Perl to throw me an error as $999 variable is not defined, but perl execu

Re: variable definition error not caught when using strict and warnings

2012-11-09 Thread Andy Bach
On Fri, Nov 9, 2012 at 11:08 AM, Nemana, Satya wrote: > > if ($999 == 1056) > { > print ("\nequal"); > } > else > { > print ("\nnot equal"); > } > > What I expect: Perl to throw me an error as $999 variable is not defined, > but perl executes the code with a warning.(I don't expect the co

Re: variable definition error not caught when using strict and warnings

2012-11-09 Thread Robert Wohlfarth
On Fri, Nov 9, 2012 at 11:08 AM, Nemana, Satya wrote: > Program: > use strict; > use warnings; > > if ($999 == 1056) > { > print ("\nequal"); > } > else > { > print ("\nnot equal"); > } > > What I expect: Perl to throw me an error as $999 variable is not defined, > but perl executes the c

variable definition error not caught when using strict and warnings

2012-11-09 Thread Nemana, Satya
Hi I am a little confused with this program Program: use strict; use warnings; if ($999 == 1056) { print ("\nequal"); } else { print ("\nnot equal"); } What I expect: Perl to throw me an error as $999 variable is not defined, but perl executes the code with a warning.(I don't expect th

Re: strict and warnings

2005-01-14 Thread JupiterHost.Net
So it costs 3% more every ten million times it runs, the benefits of leaving it in are much more valuabel than 3%/1000 :) Actually, what happens is that importing those pragma cause flags to be set (eg $^H, see `perldoc perlvar`). Perl checks these flags during certain operations. If the fl

Re: strict and warnings

2005-01-14 Thread Peter Scott
ines out of the code. Do they slow down how >perl processes the programs? Does it hurt to leave them in? I wrote an entire chapter on strict and warnings in "Perl Medic", so that the reader might understand their importance and operation. Leave them in. Always. If you have a program that

Re: strict and warnings

2005-01-13 Thread Chris Devers
On Thu, 13 Jan 2005, Randy W. Sims wrote: > But, I don't really worry about it. I've never used anything like that > in my code. If there are speed problems, there are usually better > candidates for optimization. I have never had to remove, or even think > about removing, either pragma for spe

Re: strict and warnings

2005-01-13 Thread Randy W. Sims
JupiterHost.Net wrote: Chris Devers wrote: On Thu, 13 Jan 2005, Dave Kettmann wrote: [...] Some of the time I see them say that the [strict / warnings] pragmas are good for developing programs/scripts. The way it is worded some times it seems as if after the program is written and in 'producti

Re: strict and warnings

2005-01-13 Thread JupiterHost.Net
ger remember how it works, or (more typically) someone else is maintaining it and they have to figure out what your intentions were. Agreed! If I'm given code to work with I feel much better if it already ahs strict and warnings, at least I know they put some effort into writing it and it

Re: strict and warnings

2005-01-13 Thread Chris Devers
On Thu, 13 Jan 2005, Dave Kettmann wrote: > [...] Some of the time I see them say that the [strict / warnings] > pragmas are good for developing programs/scripts. The way it is worded > some times it seems as if after the program is written and in > 'production' to take these lines out of the c

Re: strict and warnings

2005-01-13 Thread Randy W. Sims
Dave Kettmann wrote: Hello all, I have seen in quite a few posts to the list from the non-beginners, who I think all of us beginners appreciate them taking their time to help us true beginners, make some references to the strict and warnings pragmas. So I have a question about them. Some of the

Re: strict and warnings

2005-01-13 Thread John W. Krahn
Dave Kettmann wrote: Hello all, Hello, I have seen in quite a few posts to the list from the non-beginners, who I think all of us beginners appreciate them taking their time to help us true beginners, make some references to the strict and warnings pragmas. So I have a question about them. Some of

Re: strict and warnings

2005-01-13 Thread JupiterHost.Net
Dave Kettmann wrote: Hello all, hello, I have seen in quite a few posts to the list from the non-beginners, who I think all of us beginners appreciate them taking their time to help us true beginners, make some references to the strict and warnings pragmas. So I have a question about them. Some

strict and warnings

2005-01-13 Thread Dave Kettmann
Hello all, I have seen in quite a few posts to the list from the non-beginners, who I think all of us beginners appreciate them taking their time to help us true beginners, make some references to the strict and warnings pragmas. So I have a question about them. Some of the time I see them say

RE: use strict and warnings...

2002-03-07 Thread Nikola Janceski
002 12:53 PM To: 'Tanton Gibbs'; Beginners (E-mail) Subject: RE: use strict and warnings... the our works... now I got a crap load of errors with: Can't use string ("main::a") as a SCALAR ref while "strict refs" in use at /xxxx/TempSorter.pm line 114. I gotta rea

RE: use strict and warnings...

2002-03-07 Thread Nikola Janceski
the our works... now I got a crap load of errors with: Can't use string ("main::a") as a SCALAR ref while "strict refs" in use at //TempSorter.pm line 114. I gotta read the docs on use strict and warnings. I am using ${caller()."::a"} #line 114 in my prog

Re: use strict and warnings...

2002-03-07 Thread Jenda Krynicky
From: Nikola Janceski <[EMAIL PROTECTED]> > I am going through my old code and adding: > use strict; > use warnings; > > And I am running into some problems. I created a module (that I know > works). > > [ snip FILE: TempSorter.pm ] > ## Packages used > package TempSorter; > u

Re: use strict and warnings...

2002-03-07 Thread Tanton Gibbs
OOPS! don't put the comma in the qw! use vars qw(@ISA @EXPORT); - Original Message - From: "Tanton Gibbs" <[EMAIL PROTECTED]> To: "Nikola Janceski" <[EMAIL PROTECTED]>; "Beginners (E-mail)" <[EMAIL PROTECTED]> Sent: Thursday, March 0

Re: use strict and warnings...

2002-03-07 Thread Tanton Gibbs
o: "Beginners (E-mail)" <[EMAIL PROTECTED]> Sent: Thursday, March 07, 2002 12:03 PM Subject: use strict and warnings... > I am going through my old code and adding: > use strict; > use warnings; > > And I am running into some problems. I created a module (tha

use strict and warnings...

2002-03-07 Thread Nikola Janceski
I am going through my old code and adding: use strict; use warnings; And I am running into some problems. I created a module (that I know works). [ snip FILE: TempSorter.pm ] ## Packages used package TempSorter; use Exporter; use strict; ### GLOBAL VARIABLES @ISA = qw(Exporter); @EXPORT = qw( w