Re: cvs: pear /Math_Vector Tuple.php

From: Date: Thu, 25 Apr 2002 02:03:57 +0000
Subject: Re: cvs: pear /Math_Vector Tuple.php
References: 1  Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-3539@lists.php.net to get a copy of this message
On Thu, 2002-04-25 at 01:39, Jesus M. Castagnetto wrote: > jmcastagnetto Wed Apr 24 19:39:22 2002 EDT > > Modified files: > /pear/Math_Vector Tuple.php > Log: > Constructor user a PEAR_Error w/ PEAR_ERROR_DIE mode when failing > renamed compact() to squeezeHoles() > > > Index: pear/Math_Vector/Tuple.php > diff -u pear/Math_Vector/Tuple.php:1.1 pear/Math_Vector/Tuple.php:1.2 > --- pear/Math_Vector/Tuple.php:1.1 Tue Apr 23 18:04:00 2002 > +++ pear/Math_Vector/Tuple.php Wed Apr 24 19:39:21 2002 > @@ -16,7 +16,7 @@ > // | Authors: Jesus M. Castagnetto <jmcastagnetto@php.net> | > // +----------------------------------------------------------------------+ > // > -// $Id: Tuple.php,v 1.1 2002/04/23 22:04:00 jmcastagnetto Exp $ > +// $Id: Tuple.php,v 1.2 2002/04/24 23:39:21 jmcastagnetto Exp $ > // > > require_once "PEAR.php"; > @@ -53,17 +53,18 @@ > if (is_array($data) || !is_array($data[0])) { > $this->data = $data; > } else { > - return new PEAR_Error("An unidimensional array is needed to initialize a > Vector"); > + new PEAR_Error("An unidimensional array is needed to initialize a Tuple", > + null, PEAR_ERROR_DIE); You don't need to do this anymore. This is all you need: PEAR::raiseError("message"); Unless something really critial is wrong, you should not specify an error level at all when raising the error, because then error handlers will not be able to catch it. - Stig

« previous php.pear.cvs (#3539) next »