Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine

Re: Re: Re: Re: detecting $& usage

by greatdane (Beadle)
on Jan 27, 2004 at 22:51 UTC ( #324558=note: print w/replies, xml ) Need Help??

in reply to Re: Re: Re: detecting $& usage
in thread detecting $& usage

Thanks to everyone for all the help. This is a great site! Yes, the engineers are smart and numerous. Its hard to stop all the engineers from coding the wrong thing. Currently, the only indicator is a servere code slow down. I would prefer a more explicit indicator - a warning or blocked access. Thus, this thread. Scanning the user code is not that useful as many engineers will include (require/use) code from libraries. So, the check difficult. Its unfortunate that the test of "defined $&" causes the slow down. I will have to try the blocking tricks.

Replies are listed 'Best First'.
Re: Re: Re: Re: Re: detecting $& usage
by demerphq (Chancellor) on Jan 30, 2004 at 12:19 UTC

    I think you may want to reengineer what is happening a bit.

    Basically what im thinking is that you have a manager script that prepares all the appropriate stuff, and then spawns a new perl to actually run the engineer code. Thus the engineer code runs in a seperate process under a seperate perl every time. Youll get some slowdown from marshalling data between the manager script and the worker script, but it should be workable and overall resolve the problem of unexpected use of $&.

    Also with regard to your library usage, surely you can do a grep of your lib directories and simply remove or modify any library that has the offending vars in it. Obviously it would make your system non-standard, but it sounds like you have somewhat unusual requirements.


      First they ignore you, then they laugh at you, then they fight you, then you win.
      -- Gandhi

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://324558]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (4)
As of 2022-12-03 15:10 GMT
Find Nodes?
    Voting Booth?

    No recent polls found