[Top] [All Lists]

Re: OO confusion

Subject: Re: OO confusion
From: Randal L. Schwartz
Date: Sun, 11 Jan 2009 10:59:34 -0800
Newsgroups: perl.beginners

>>>>> "Rob" == Rob Dixon <[email protected]> writes:

Rob> I tested the similar

Rob>   my @data = do {
Rob>     open my $fh, '<', $file or die $!;
Rob>     <$fh>;
Rob>   };

Rob> a while ago, but not on v5.10. I will see if I can find time to try it 

Ahh, but that's very different.  My suspicion is that both the last-expr
scalar of the block and the $result scalar will share the same single
payload, similar to how:

         $x = $y

doesn't actually copy the *content*... just the scalar wrapper around
the content.

Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<[email protected]> <URL:>
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See for Smalltalk and Seaside discussion

<Prev in Thread] Current Thread [Next in Thread>