develooper Front page | perl.perl5.porters | Postings from March 2000

RE: RE: A plea for more pollution

From:
Moore, Paul
Date:
March 20, 2000 02:04
Subject:
RE: RE: A plea for more pollution
Message ID:
714DFA46B9BBD0119CD000805FC1F53BDC3A4B@UKRUX002.rundc.uk.origin-it.com
From: M.J.T. Guy [mailto:mjtg@cus.cam.ac.uk]
> 
> Good point.    I was proposing to look for both "PL_na" and "na" etc.
> If a PL... symbol was found, we can assume the module has been updated
> so no POLLUTE is needed.    I'd only force POLLUTE if there were
> polluting symbols present and *no* PL... ones.

But... In the case of na, a good fix for (silly example)

    { na = 12; }

is

    { STRLEN na; na = 12; }

instead of

    { PL_na = 12; }

because access to a local variable is faster than access to a global.

So a fixed module may still refer to na rather than PL_na. (I assume you
don't propose to scan for declarations...?)

I'm not sure of the value of the heuristic approach in any case, but I
thought I'd add this datapoint...

Paul.



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About