Mercurial > octave-antonio
changeset 6629:7e2b5d0cf7ad
[project @ 2007-05-16 15:18:18 by jwe]
author | jwe |
---|---|
date | Wed, 16 May 2007 15:18:19 +0000 |
parents | d88d66f8cab6 |
children | 0fcc8d65b571 |
files | liboctave/CRowVector.cc liboctave/ChangeLog liboctave/dRowVector.cc scripts/ChangeLog scripts/general/logspace.m src/load-path.h |
diffstat | 6 files changed, 16 insertions(+), 21 deletions(-) [+] |
line wrap: on
line diff
--- a/liboctave/CRowVector.cc Wed May 16 15:11:14 2007 +0000 +++ b/liboctave/CRowVector.cc Wed May 16 15:18:19 2007 +0000 @@ -526,14 +526,8 @@ } else if (n == 1) { - if (x1 == x2) - { - retval.resize (1); - retval.elem (0) = x1; - } - else - (*current_liboctave_error_handler) - ("linspace: npoints is 1, but x1 != x2"); + retval.resize (1); + retval.elem (0) = x2; } else (*current_liboctave_error_handler)
--- a/liboctave/ChangeLog Wed May 16 15:11:14 2007 +0000 +++ b/liboctave/ChangeLog Wed May 16 15:18:19 2007 +0000 @@ -1,3 +1,9 @@ +2007-05-16 David Bateman <dbateman@free.fr> + + * dRowVector.cc (linspace): Return second argument if fewer than + two values are requested. + * CRowVector.cc (linspace): Likewise. + 2007-04-27 John W. Eaton <jwe@octave.org> * lo-mappers.cc (signum (const Complex&)): Special case for (0, 0).
--- a/liboctave/dRowVector.cc Wed May 16 15:11:14 2007 +0000 +++ b/liboctave/dRowVector.cc Wed May 16 15:18:19 2007 +0000 @@ -335,14 +335,8 @@ } else if (n == 1) { - if (x1 == x2) - { - retval.resize (1); - retval.elem (0) = x1; - } - else - (*current_liboctave_error_handler) - ("linspace: npoints is 1, but x1 != x2"); + retval.resize (1); + retval.elem (0) = x2; } else (*current_liboctave_error_handler)
--- a/scripts/ChangeLog Wed May 16 15:11:14 2007 +0000 +++ b/scripts/ChangeLog Wed May 16 15:18:19 2007 +0000 @@ -1,3 +1,8 @@ +2007-05-16 John W. Eaton <jwe@octave.org> + + * general/logspace.m: Return second arg if fewer than two values + are requested. + 2007-05-14 John W. Eaton <jwe@octave.org> * plot/__go_draw_figure__.m: Ensure that a reset commands starts
--- a/scripts/general/logspace.m Wed May 16 15:11:14 2007 +0000 +++ b/scripts/general/logspace.m Wed May 16 15:18:19 2007 +0000 @@ -77,10 +77,6 @@ print_usage (); endif - if (npoints < 2) - error ("logspace: npoints must be greater than 2"); - endif - if (length (x1) == 1 && length (x2) == 1) x2_tmp = x2; if (x2 == pi)
--- a/src/load-path.h Wed May 16 15:11:14 2007 +0000 +++ b/src/load-path.h Wed May 16 15:18:19 2007 +0000 @@ -339,7 +339,7 @@ void do_display (std::ostream& os) const; - std::string system_path (void) const { return sys_path; } + std::string do_system_path (void) const { return sys_path; } void add_to_fcn_map (const dir_info& di, bool at_end) const; };