perl-embperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Villu Roogna" <realm...@gmail.com>
Subject use and Execute differences
Date Wed, 10 Oct 2007 08:18:13 GMT
Hello,

Searched through the documentation and mailing lists but could not find the
exact information.
What are the most important differences between using normal perl module
with:

use Package::Module

$obj = Package::Module->new();

or using

$obj = Execute({object => 'package/module.pl', syntax => 'Perl'});
$obj->new();

When we think about reusability then the first strategy (with use) would be
better since we can later use these modules with other systems.
Also I think memory usage would be more efficient since use only loads
modules when necessary.

But would there be any cases where the latter (Execute) would be more
preferable? And how about its memory usage?

Using Embperl 2.2.0.

With kind regards,
Villu Roogna

Mime
View raw message