[Templates-cvs] cvs commit: TT3/lib/Template/Directive Wrapper.pm

cvs@template-toolkit.org cvs@template-toolkit.org
Fri, 03 Dec 2004 14:32:46 +0000


cvs         04/12/03 14:32:46

  Modified:    lib/Template/Directive Wrapper.pm
  Log:
  * changed parse_template_name() to parse_path()
  
  Revision  Changes    Path
  1.6       +6 -6      TT3/lib/Template/Directive/Wrapper.pm
  
  Index: Wrapper.pm
  ===================================================================
  RCS file: /template-toolkit/TT3/lib/Template/Directive/Wrapper.pm,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- Wrapper.pm	2004/11/18 17:38:37	1.5
  +++ Wrapper.pm	2004/12/03 14:32:45	1.6
  @@ -15,7 +15,7 @@
   #   modify it under the same terms as Perl itself.
   #
   # REVISION
  -#   $Id: Wrapper.pm,v 1.5 2004/11/18 17:38:37 abw Exp $
  +#   $Id: Wrapper.pm,v 1.6 2004/12/03 14:32:45 abw Exp $
   #
   #========================================================================
   
  @@ -26,7 +26,7 @@
   use Template::Directive;
   use base qw( Template::Directive );
   
  -our $VERSION = sprintf("%d.%02d", q$Revision: 1.5 $ =~ /(\d+)\.(\d+)/);
  +our $VERSION = sprintf("%d.%02d", q$Revision: 1.6 $ =~ /(\d+)\.(\d+)/);
   our $DEBUG   = 0 unless defined $DEBUG;
   our $ERROR   = '';
   our $KEYWORD = 'WRAPPER';
  @@ -43,7 +43,7 @@
       my $parser = $match->{ parser }
           || return $self->error('no parser defined');
   
  -    my $template = $parser->parse_template_name($textref)
  +    my $name = $parser->parse_path($textref)
           || return $self->error('missing template name in ',
                                  $self->keyword($match), ' directive');
   
  @@ -52,11 +52,11 @@
                                  $self->keyword($match), ' directive');
   
       if (my $body = $handler->rollback()) {
  -        return $handler->expr([ wrapper => $template, $args, $body ])
  +        return $handler->expr([ wrapper => $name, $args, $body ])
               || $self->error($handler->error());
       }
       else {
  -        return $handler->start_expr([ wrapper => $template, $args ],
  +        return $handler->start_expr([ wrapper => $name, $args ],
                                       { expects => $EXPECTS,
                                         keyword => $match->{ keyword },
                                         line    => $match->{ line },
  @@ -94,7 +94,7 @@
   
   =head1 VERSION
   
  -$Revision: 1.5 $
  +$Revision: 1.6 $
   
   =head1 COPYRIGHT