Re: Apache::Registry and clearing package name space

2000-05-12 Thread Doug MacEachern
On Sun, 7 May 2000, Richard Chen wrote: > Instead of the line > undef &$fullname; > which undef's the source subroutine, one should use > *{$fullname}=sub {}; ah, good trick! this also solves the problem for aliased arrays/hashes/scalars > This fix is obvious because that i

Re: Apache::Registry and clearing package name space

2000-05-07 Thread Richard Chen
I found that a modified version of scrub_package (written by Mark-Jason Dominus and described in perlfaq7) works correctly and more efficiently than Apache::PerlRun->flush_namespace Here is the original scrub_package subroutine: sub scrub_package { no strict 'refs';

Re: Apache::Registry and clearing package name space

2000-05-04 Thread Richard Chen
Unfortunately, the crucial part about clearing/removing subroutine alias does not work when using Apache::PerlRun->flush_namespace('Q') I suspect this is a bug in PerlRun. Here is the demo program (It can be run from the command line) $ cat tmp.pl #!/usr/bin/perl -w use strict; use Apache

Re: Apache::Registry and clearing package name space

2000-05-03 Thread Doug MacEachern
On Mon, 1 May 2000, Richard Chen wrote: > Hello, > I am having a problem clearing variables and aliases > in a temporary package name space. The source of the problem > is in making legend cgi scripts work under Apache::Registry. > But the problem can be isolated and shown by the following

Apache::Registry and clearing package name space

2000-05-01 Thread Richard Chen
Hello, I am having a problem clearing variables and aliases in a temporary package name space. The source of the problem is in making legend cgi scripts work under Apache::Registry. But the problem can be isolated and shown by the following demo program: $ cat foo.cgi #!/usr/bin/perl -w u