develooper Front page | perl.libwww | Postings from March 2003

Re: URI Bug?

Thread Previous | Thread Next
From:
Reinier Post
Date:
March 4, 2003 04:40
Subject:
Re: URI Bug?
Message ID:
20030304123922.GE1174@svis02.win.tue.nl
On Sun, Nov 24, 2002 at 02:56:56PM -0800, Randal L. Schwartz wrote:
> >>>>> "Gisle" == Gisle Aas <gisle@ActiveState.com> writes:
> 
> >> I'd be happy to learn of a better way to do this, and I'm sure my list
> >> is not complete anyway.
> 
> Gisle> I suggest either:
> 
> Gisle>     $url->host(ip_address($url->host)) if $url->can("host");
> 
> Why bother with "can"?  Don't they all inherit from a common base class?
> Just put a "host" in the common base class that returns itself.

Shouldn't it rather return undef?

In any case I'd love to see this fixed.  The present behaviour is counterintuitive.

-- 
Reinier

Thread Previous | Thread Next


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