On Wed, 3 May 2000, Geoffrey Young wrote:
> interesing behavior - print behaves the same way...
http://perl.apache.org/guide/porting.html#Apache_print_and_CORE_print_
Under mod_perl CORE::print() will redirect its data to Apache::print()
since the STDOUT filehandle is tied to the Apache module.
> however, when you concat the reference to another scalar things work
> right...
>
> $r->print($foo.\$foo);
> yields:
> fooSCALAR(0xXWHOOPSX)
>
> --Geoff
>
>
> > -----Original Message-----
> > From: Jeffrey W. Baker [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, May 03, 2000 1:37 PM
> > To: [EMAIL PROTECTED]
> > Subject: Why does $r->print() dereference its arguments?
> >
> >
> > Apache::print() dereferences its arguments. For example, this code:
> >
> > my $foo = "bar";
> > $r->print(\$foo);
> >
> > prints "bar" instead of the expected SCALAR(0xDEADBEEF). Can anyone
> > explain the purpose of this behavior, or is it a misfeature?
> > In my case,
> > this is not the desired behavior.
> >
> > -jwb
> >
>
______________________________________________________________________
Stas Bekman | JAm_pH -- Just Another mod_perl Hacker
http://stason.org/ | mod_perl Guide http://perl.apache.org/guide
mailto:[EMAIL PROTECTED] | http://perl.org http://stason.org/TULARC/
http://singlesheaven.com| http://perlmonth.com http://sourcegarden.org
----------------------------------------------------------------------