I kept getting a lot of spurious warnings in perl 5.6.1 when using the
experimental VIEW directive in my multi-million pound ecommerce
solution:
Useless use of private variable in void context at
/space/.template_cache//space/templates/library/global/header.ttc line
83, <ZONEFILE> line 377.
The attached patch should stop these warnings.
alex
--
alex <[EMAIL PROTECTED]>
Index: Directive.pm
===================================================================
RCS file: /template-toolkit/Template2/lib/Template/Directive.pm,v
retrieving revision 2.17
diff -u -r2.17 Directive.pm
--- Directive.pm 2002/08/08 11:59:15 2.17
+++ Directive.pm 2003/03/24 14:21:39
@@ -784,7 +784,6 @@
return <<EOF;
# VIEW
do {
- my \$output = '';
my \$oldv = \$stash->get('view');
my \$view = \$context->view($hash);
\$stash->set($name, \$view);
@@ -794,7 +793,7 @@
\$stash->set('view', \$oldv);
\$view->seal();
- \$output;
+ return '';
};
EOF
}