Skip to content

Commit

Permalink
Fixed merge conflict in Credits.pod
Browse files Browse the repository at this point in the history
  • Loading branch information
abw committed Apr 24, 2014
2 parents 3a13538 + 3ba3ccf commit 17d4832
Show file tree
Hide file tree
Showing 4 changed files with 94 additions and 25 deletions.
9 changes: 5 additions & 4 deletions Makefile.PL
Original file line number Diff line number Diff line change
Expand Up @@ -146,10 +146,11 @@ my %opts = (
'PMLIBDIRS' => [ 'lib' ],
'DIR' => [ ],
'PREREQ_PM' => {
'AppConfig' => $TT_APPCONFIG_VERSION,
'File::Spec' => $TT_FILE_SPEC_VERSION,
'File::Temp' => $TT_FILE_TEMP_VERSION,
'Scalar::Util' => 0,
'AppConfig' => $TT_APPCONFIG_VERSION,
'File::Spec' => $TT_FILE_SPEC_VERSION,
'File::Temp' => $TT_FILE_TEMP_VERSION,
'Scalar::Util' => 0,
'Test::LeakTrace' => 0,
},
'META_MERGE' => {
'resources' => {
Expand Down
36 changes: 17 additions & 19 deletions lib/Template/Manual/Credits.pod
Original file line number Diff line number Diff line change
Expand Up @@ -78,25 +78,23 @@ Please let me know if you think anyone is missing from this list.
If you submit a patch/pull request then please make sure you add your
own name to this list and include it in the changes.
Chuck Adams, Stephen Adkins, Ivan Adzhubey, Mark Anderson, Bradley Baetz,
Thierry-Michel Barral, Craig Barratt, Stas Bekman, Robin Berjon, Tony Bowden,
Neil Bowers, Leon Brocard, Lyle Brooks, Norbert Buchmüller, Dave Cash, Piers
Cawley, Darren Chamberlain, Timmy Chan, Eric Cholet, Chromatic, Nik Clayton,
Tosh Cooey, Dave Cross, Chris Dean, Francois Desarmenien, Horst Dumcke, Mark
Fowler, Michael Fowler, Brain Fraser, Kenny Gatdula, Axel Gerstmair, Jay Hannah,
Dylan William Hardison, Perrin Harkins, Bryce Harrington, Dave Hodgkinson,
Lubomir Host, Dave Howorth, Jon Jensen, Harald Joerg, Colin Johnson, Colin
Keith, Adam Kennedy, Vivek Khera, Alexey A. Kiritchun, Rafael Kitover, Andreas
Koenig, Ivan Kurmanov, Denis F. Latypoff, Hans von Lengerke, John Lightsey,
Jonas Liljegren, Simon Napiorkowski, Breno G. de Oliveira, Leslie Michael
Orchard, Paul Orrock, Jonathon Padfield, Steve Peters, Briac PilprE<eacute>,
Yuri Pimenov, Martin Portman, Marc Remy, Slaven Rezic, Jess Robinson, Josh
Rosenbaum, Christian Schaffner, Mike Schilli, Randal L. Schwartz, Paul Seamons,
Paul Sharpe, Ricardo Signes, Ville SkyttE<auml>, Barrie Slaymaker, David
Steinbrunner, Doug Steinwand, Michael Stevens, Autrijus Tang, Drew Taylor, Rod
Taylor, Swen Thuemmler, Richard Tietjen, Ben Tilly, Stathy G. Touloumis, Jim
Vaughan, Simon Wilcox, Chris Winters.
Amiri Barksdale, Thierry-Michel Barral, Craig Barratt, Stas Bekman, Robin Berjon,
Tony Bowden, Neil Bowers, Leon Brocard, Lyle Brooks, Norbert Buchmüller,
Dave Cash, Piers Cawley, Darren Chamberlain, Timmy Chan, Eric Cholet, Chromatic,
Nik Clayton, Tosh Cooey, Dave Cross, Chris Dean, Francois Desarmenien, Horst Dumcke,
Mark Fowler, Michael Fowler, Brian Fraser, Kenny Gatdula, Axel Gerstmair, Jay Hannah, Dylan
William Hardison, Perrin Harkins, Bryce Harrington, Dave Hodgkinson, Lubomir
Host, Dave Howorth, Jon Jensen, Harald Joerg, Colin Johnson, Colin Keith,
Adam Kennedy, Vivek Khera, Alexey A. Kiritchun, Rafael Kitover, Andreas
Koenig, Ivan Kurmanov, Denis F. Latypoff, Hans von Lengerke, Jonas Liljegren,
Simon Napiorkowski, Breno G. de Oliveira, Leslie Michael Orchard, Paul Orrock,
Jonathon Padfield, Steve Peters, Briac PilprE<eacute>, Yuri Pimenov, Martin
Portman, Marc Remy, Slaven Rezic, Jess Robinson, Josh Rosenbaum, Christian
Schaffner, Mike Schilli, Randal L. Schwartz, Paul Seamons, Paul Sharpe,
Ricardo Signes, Ville SkyttE<auml>, Barrie Slaymaker, David Steinbrunner, Doug
Steinwand, Michael Stevens, Autrijus Tang, Drew Taylor, Rod Taylor, Swen
Thuemmler, Richard Tietjen, Ben Tilly, Stathy G. Touloumis, Jim Vaughan, Simon
Wilcox, Chris Winters.
=cut

Expand Down
4 changes: 2 additions & 2 deletions lib/Template/Plugin/Filter.pm
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ sub factory {
# weaken($this);

if ($self->{ _DYNAMIC }) {
return $self->{ _DYNAMIC_FILTER } ||= [ sub {
return [ sub {
my ($context, @args) = @_;
my $config = ref $args[-1] eq 'HASH' ? pop(@args) : { };

Expand All @@ -84,7 +84,7 @@ sub factory {
}, 1 ];
}
else {
return $self->{ _STATIC_FILTER } ||= sub {
return sub {
$this->filter(shift);
};
}
Expand Down
70 changes: 70 additions & 0 deletions t/plugin_leaks.t
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
#============================================================= -*-perl-*-
#
# t/plugin_leaks.t
#
# Test the Template::Plugins module.
#
# Written by Andy Wardley <abw@kfs.org>
#
# Copyright (C) 1996-2000 Andy Wardley. All Rights Reserved.
# Copyright (C) 1998-2000 Canon Research Centre Europe Ltd.
#
# This is free software; you can redistribute it and/or modify it
# under the same terms as Perl itself.
#
# $Id$
#
#========================================================================

use strict;
use lib qw( t/lib ./lib ../lib ../blib/arch );
use Template::Test;
use Template::Plugins;
use Template::Constants qw( :debug );
use Test::LeakTrace;
use Cwd qw( abs_path );
$^W = 1;
my $DEBUG = grep(/^--?d(debug)?$/, @ARGV);

ntests(2);

my $dir = abs_path(-d 't' ? 't/test/plugin' : 'test/plugin');
my $src = abs_path(-d 't' ? 't/test/lib' : 'test/lib');
unshift(@INC, $dir);

my ($input, $output);
my $output = '';

# Copy input parsing from Template::Test::test_expect
eval {
local $/ = undef;
$input = <DATA>;
};

$input =~ s/^#.*?\n//gm;
$input = $' if $input =~ /\s*--\s*start\s*--\s*/;
$input = $` if $input =~ /\s*--\s*stop\s*--\s*/;


# Declare a processor
my $tt1 = Template->new({
PLUGIN_BASE => [ 'MyPlugs', 'Template::Plugin' ],
INCLUDE_PATH => $src,
DEBUG => $DEBUG ? DEBUG_PLUGINS : 0,
}) || die Template->error();

# Check whether processing with a double-included filter produces more than 4 leaks.
leaks_cmp_ok {
$tt1->process(\$input, {}, \$output);
} '<', 4;

# There should be none at all here.
no_leaks_ok {
$tt1->process(\$input, {}, \$output);
} "No leaks at all";

__END__
[% USE Simple -%]
[% 'world' | simple %]
[% INCLUDE simple2 %]
[% 'hello' | simple %]

0 comments on commit 17d4832

Please sign in to comment.