enlightened perl organisation

enlightened |en'litnd|: adjective:
having or showing a rational, modern, and well-informed outlook

  

Planet Perl Iron Man

Daily archive for Tuesday, 20 August 2013

< Younger posts | Older posts >
Sinan Unur (Sinan): Read select lines from a file using Perl

In this Stackoverflow question, the poster wants to know how to read only those lines that whose immediate predecessor and successor lines satisfies certain conditions. For simplicity, the OP specifies that only lines that are not immediately precede [...]

Sinan Unur (Sinan): Read select lines from a file using Perl

In this Stackoverflow question, the poster wants to know how to read only those lines whose immediate predecessor and successor lines satisfy certain conditions. For simplicity, the OP specifies that only lines that are not immediately preceded and f [...]

JT Smith: Posted Released Ouch 0.0404 to JT Smith
Pushed Ouch 0.0404 to CPAN. It turns out I was using some Perl 5.10 and 5.12 features (use parent and use overload respectively) and that was causing some CPAN testers errors, and also problems for folks on old Perls.  So...
Tokuhiro Matsuno: 複雑なデータ構造の中にうまっているデータのパスをさがす方法

Perl5 の場合、Data::DPath をつかえば、

my $data = {
    foo => {
        bar => 'candy',
    },
};

のようなデータから、

say dpath('/foo/bar')->match($hashref);

などとして、candy を簡単にとりだすことができます。

しかし、ここで、たとえば以下のように複雑なデータになってしまった場合は、DPath をつくるのがまじめんどいかんじになります。

my $data [...]
< Younger posts | Older posts >