bless is good parts of Perl language

Recently I feel bless is good parts of Perl language strongly.

package Point;

use strict;
use warnings;

sub new {
my $class = shift;

my $self = {@_};

return bless $self, $class;
}

sub x { shift->{x} }
sub y { shift->{y} }

This is smallest class which have only read accessors. Very clean and compact.

This class work well completely.

use Point;
my $point = Point->new(x => 1, y => 2);
my $x = $point->x;

Some pe…

SPVM Document beta 1.0

I start to write SPVM Document beta 1.0 by Japanese.

SPVM Doument beta 1.0(Japanese)

The SSL certificate of the domain of the Perl 5 repository has expired

The SSL certificate of the domain of the Perl 5 repository has expired from 10/19.

https://perl5.git.perl.org/perl.git

The way to create Class with only Perl core language.

Do you know that Perl have enough object-oriented features in core language?

Not necessarily you need to use CPAN module to do object-oriented programing.

I write the entry "The way to create Class with only Perl core language".

The way to create Class with only Perl core features

package Point;

sub new {
my $class = shift;

my $self = {
x => 0,
y => 0,
@_,…

Perl Event Roppongi.pm #1 at 2018/9/14

Perl Event Roppongi.pm is opened at #1 2018/9/14

I get some pictures.

See all pictures Roppongi.pm Pictures