Bug in LibWWW perl + Data::Dumper (libwwwperl refs are strange)

Michael De La Rue (mikedlr@indy.unipress.waw.pl)
Thu, 03 Oct 1996 16:33:14 +0200


(sorry if you are getting this twice.  I sent it to the wrong mailing
list by accident) 

Does anyone have any comments on the
following.  It assumes Data::Dumper 

Here's a demonstration script

--------------
use Data::Dumper;   use URI::URL;
$fred = new fred;
$url = new URI::URL "http://goo/";
print "fred: ", $fred, " url: ", $url, "\n";  
print "dumpfred: ", Dumper($fred);
print " dumpurl: ", Dumper($url);
package fred;
sub new { my $self={}; return bless $self, shift;}
-------------

on my machine it gives 

-------------------
Can't handle  type. at breakperl line 6
fred: fred=HASH(0x8070048) url: http://goo/
dumpfred: $VAR1 = bless( {}, 'fred' );
-------------------

normally if I do `ref $object' I get get it's class, type and address.
On a URI::URL I only get the class.  I guess this is wrong, and when I
followed this into Data::Dumper it seemed that this caused it not to
work.. 

I guess this might be the overloading of the "" operator which is
causing this bug?

	Michael

	    <http://www.tardis.ed.ac.uk/~mikedlr/biography.html>
  Scottish Climbing Archive: <http://www.tardis.ed.ac.uk/~mikedlr/climbing/>
Linux/Unix clone@ftp://src.doc.ic.ac.uk/packages/linux/sunsite.unc-mirror/docs/