Just remove the debug statements once and put them in a second script to be exec'd based on command line parameter.
> -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]]On Behalf Of > Nick Djurovich > Sent: Monday, November 12, 2001 12:45 PM > To: PERLMAILINGLIST > Subject: How to omit lines from execution in a perl program > > > Hi, > > I have a perl script with lots of debug statements. I want > to be able to run the script without the debug statements. > Is there a way to do this in runtime ? > > I can currently set a debug variable that prevents output, but > I would rather the debug statements were never executed for > optimum speed. > > I have thought of a way, in which at the start, if specified > by a command line parameter, it slurps itself up into a large > string, removing the debug statements and then evaluating > the string, and then exits. Yuck. > > Regards > > Nick Djurovich > ============================ > Software Development Manager > mediaMailGroup > Colchester > UK > _______________________________________________ > Perl-Win32-Users mailing list > [EMAIL PROTECTED] > http://listserv.ActiveState.com/mailman/listinfo/perl-win32-users > > _______________________________________________ Perl-Win32-Users mailing list [EMAIL PROTECTED] http://listserv.ActiveState.com/mailman/listinfo/perl-win32-users