[Bast-commits] r3685 - local-lib/1.000/trunk/lib/local
matthewt at dev.catalyst.perl.org
matthewt at dev.catalyst.perl.org
Fri Aug 17 16:51:53 GMT 2007
Author: matthewt
Date: 2007-08-17 16:51:52 +0100 (Fri, 17 Aug 2007)
New Revision: 3685
Modified:
local-lib/1.000/trunk/lib/local/lib.pm
Log:
renamed compose to pipeline cos Lemm at netgoth.org.uk#orgy convinced me it made more sense
Modified: local-lib/1.000/trunk/lib/local/lib.pm
===================================================================
--- local-lib/1.000/trunk/lib/local/lib.pm 2007-08-16 15:23:18 UTC (rev 3684)
+++ local-lib/1.000/trunk/lib/local/lib.pm 2007-08-17 15:51:52 UTC (rev 3685)
@@ -19,15 +19,15 @@
$class->setup_local_lib_for($path);
}
-sub compose;
+sub pipeline;
-sub compose {
+sub pipeline {
my @methods = @_;
my $last = pop(@methods);
if (@methods) {
\sub {
my ($obj, @args) = @_;
- $obj->${compose @methods}(
+ $obj->${pipeline @methods}(
$obj->$last(@args)
);
};
@@ -44,13 +44,13 @@
{ package Foo; sub foo { -$_[1] } sub bar { $_[1]+2 } sub baz { $_[1]+3 } }
my $foo = bless({}, 'Foo');
-ok($foo->${compose qw(foo bar baz)}(10) == -15);
+ok($foo->${pipeline qw(foo bar baz)}(10) == -15);
=cut
sub resolve_path {
my ($class, $path) = @_;
- $class->${compose qw(
+ $class->${pipeline qw(
resolve_relative_path
resolve_home_path
resolve_empty_path
More information about the Bast-commits
mailing list