develooper Front page | perl.perl5.porters | Postings from January 2005

Re: XSLoader for older perls

Thread Previous | Thread Next
From:
Nick Ing-Simmons
Date:
January 3, 2005 08:46
Subject:
Re: XSLoader for older perls
Message ID:
20050103164638.1894.10@llama.ing-simmons.net
Dave Rolsky <autarch@urth.org> writes:
>On Sat, 20 Nov 2004, Michael G Schwern wrote:
>
>> On Sat, Nov 20, 2004 at 12:02:01PM -0600, Dave Rolsky wrote:
>>> I do this in DateTime.pm:
>>>
>>> 	    if ( $] >= 5.006 )
>>> 	    {
>>> 		require XSLoader;
>>> 		XSLoader::load( 'DateTime', $DateTime::VERSION );
>>> 	    }
>>> 	    else
>>> 	    {
>>> 		require DynaLoader;
>>> 		@DateTime::ISA = 'DynaLoader';
>>> 		DateTime->bootstrap( $DateTime::VERSION );
>>> 	    }
>>
>> Here's a stupid question.  If two lines of XSLoader is easily replaced
>> with three lines of DynaLoader... why use XSLoader at all?
>
>Supposedly it uses less memory and is faster, but I could be wrong since I 
>don't really know what it's doing anyway.

Also the DynaLoader thing puts itself in ISA which means your 
class inherits a bunch of things from DynaLoader you may not want.


>
>
>-dave
>
>/*===========================
>VegGuide.Org
>Your guide to all that's veg.
>===========================*/


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