Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

29 lines (21 sloc) 0.393 kb
define point {
number x, y;
draw { &draw_point; }
}
define line {
point start, end;
draw { &draw_line; }
}
point P(x = 2, y = 3);
line L(start=P, end=(4, 5));
__END__
sub draw_point {
my $env = shift;
my $s = hash2str($env->var_hash);
print "DRAWING POINT ($s)\n";
}
sub draw_line {
my $env = shift;
my $s = hash2str($env->var_hash);
print "DRAWING LINE ($s)\n";
}
Jump to Line
Something went wrong with that request. Please try again.