From 2350ab1b6a2cae5a89d46b020d968f555c21f5d0 Mon Sep 17 00:00:00 2001 From: Gabriel Wicke Date: Sun, 28 Mar 2004 21:03:16 +0000 Subject: [PATCH] minor bug fix that caused the default keyword not to work, small performance improvement --- PHPTAL-NP-0.7.0/libs/PHPTAL/Expression.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/PHPTAL-NP-0.7.0/libs/PHPTAL/Expression.php b/PHPTAL-NP-0.7.0/libs/PHPTAL/Expression.php index 5e4a63d25c..81bae03397 100644 --- a/PHPTAL-NP-0.7.0/libs/PHPTAL/Expression.php +++ b/PHPTAL-NP-0.7.0/libs/PHPTAL/Expression.php @@ -267,7 +267,7 @@ class PHPTAL_Expression function _evaluateSequence($seq) { $temp = $this->_gen->newTemporaryVar(); - $this->_gen->doIf('!$__ctx__->_errorRaised'); + $this->_gen->doDo(); foreach ($seq as $s) { // skip empty parts @@ -287,13 +287,11 @@ class PHPTAL_Expression } $this->_gen->doEndDoWhile('0'); // test errorRaised - $this->_gen->doElse(); - - // $this->_gen->doAffectResult($temp, '""'); // $__ctx__->_errorRaised'); + // error handling, disabled for performance.. +/* $this->_gen->doIf('$__ctx__->_errorRaised'); $this->_gen->doAffectResult($temp, '$__ctx__->_errorRaised'); $this->_gen->execute('$__ctx__->_errorRaised = false'); - $this->_gen->endBlock(); - // ---------------- + $this->_gen->endBlock(); */ $err = $this->_useResult($temp); -- 2.20.1