sub compose { my ($f, $g) = @_; return sub { $f->($g->(@_)); } } # ... 'boldital' => &compose(&curry(\&wrap_with_html, 'i'), &curry(\&wrap_with_html, 'b')),