I try to install PDL to Windows, but I can't install PDL to Windows.
I try to install in Active Perl and Strawberry Perl.
1. Active Perl(5.16.3 32bit and PDL 2.007)
Installation of ppm is ok, but install by cpan fail.
cpan PDL
The reason is error of Devel-CheckLib-1.01. assertlib error popup and test fail.
Writing Makefile for Devel::CheckLib
Writing MYMETA.yml and MYMETA.json
cp lib/Devel/CheckLib.pm blib\lib\Devel\CheckLib.pm
C:\Perl-5.16.3\bin\perl.exe -MExtUtils::Command -e cp -- bin/use-devel-checklib blib\script\use-devel-chec…
I think there are two advantages in encapsulation.
Separation of implementation and API interfece
Advantage of encapsulation is that if you change the implementation,
you don't need to change api interface.
For example, see the following code. This is Mojo::Path source code.
package Mojo::Path;
...
sub trailing_slash { shift->_parse(trailing_slash => @_) }
sub _parse {
my ($self, $name) = (shift, shift);
unless ($self->{parts}) {
my $path = url_unescape delete($self->{path}) // '';
my $charset…
I try postderef in Perl 5.19.5. The following code don't work.
my $params = {
foo => 1,
bar => 2,
baz => 3
};
my $new_params = {};
$new_params->%{'FOO', 'BAR'} = $params->%{'foo', 'bar'};
I expect {FOO => 1, BAR => 2}.
But left side assignment don't work. Is this specification or bug?
I translate Perl Tips to English.
Perl Tips - Perl Tutorial by Code Examples
Perl have several easy to wrong points. If you use something of them, Perl programming will become smooth.
In Perl, accessor access is about 30 times slower than direct access. For example,
# Accessor access
$obj->title;
# Direct access
$obj->{title};
"$obj->title" is about 30 times slower than "$obj->{title}". In current perl, we can't replace accessor access with direct access in general way.
but in mop, we can distinguish method and attribute. If so, we may replace accessor access with direct access. I want mop to rest capability to define this fast accessor.
Steven said "$self->title" is overhead, but if fast accessor is implemented, this is no …
I released GitPrep 1.3 at 2013/10/09. You can install portable GitHub system into Unix / Linux easily. It is second major release.
Because you can install GitPrep into your own server, you can create users and repositories without limit. You can use GitPrep freely because GitPrep is free software. You can also install GitPrep into shared rental server.
GitPrep (Document and Repository)
Features added in 1.3 are:
…
method keyword is the syntax to write method simply.
method clear {
# You can omit "my $self = shift" by method keyword
$self->x;
}
And method keyword give Perl ability to know it is subroutine or method.
I think that method keyword isn't part of Meta Object Protocol even if mop use it as the part of module features. method keyword is independent feature.
If so, we can implement method keyword before mop release. Big jump is hard, small jump is good. If method keyword can work independent feature, I think it is good that method keyword is imp…
I translated "Debugger Manual" to English
Debugger Manual
Perl Debugger is very useful tool. but I think yet many people don't know the way to use Perl debugger well. If you can use debugger well, Speed of development increase and decrease bugs. Let's use debugger more!