Mercurial > octave
diff libinterp/corefcn/Cell.cc @ 20831:35241c4b696c
eliminate return statements after calls to error
* Cell.cc, __ichol__.cc, __lin_interpn__.cc, __pchip_deriv__.cc,
besselj.cc, cellfun.cc, colloc.cc, debug.cc, dlmread.cc,
dynamic-ld.cc, filter.cc, find.cc, gl2ps-renderer.cc, load-path.cc,
load-save.cc, ls-mat4.cc, ls-mat5.cc, ls-oct-text.cc, luinc.cc,
max.cc, nproc.cc, oct-hist.cc, oct-map.cc, oct-obj.cc, oct-stream.cc,
ordschur.cc, pinv.cc, pr-output.cc, profiler.cc, psi.cc, quadcc.cc,
qz.cc, rand.cc, strfind.cc, strfns.cc, sysdep.cc, toplev.cc, tril.cc,
typecast.cc, urlwrite.cc, utils.cc, variables.cc: Eliminate return
statements after calls to error.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Wed, 09 Dec 2015 14:00:43 -0500 |
parents | 25d676f9619c |
children | 48b2ad5ee801 |
line wrap: on
line diff
--- a/libinterp/corefcn/Cell.cc Tue Dec 08 17:41:32 2015 -0800 +++ b/libinterp/corefcn/Cell.cc Wed Dec 09 14:00:43 2015 -0500 @@ -294,15 +294,13 @@ { if (i < 0 || i >= cols ()) error ("invalid column selection"); - else - { - octave_idx_type nr = rows (); + + octave_idx_type nr = rows (); - retval.resize (dim_vector (nr, 1)); + retval.resize (dim_vector (nr, 1)); - for (octave_idx_type j = 0; j < nr; j++) - retval.xelem (j) = elem (j, i); - } + for (octave_idx_type j = 0; j < nr; j++) + retval.xelem (j) = elem (j, i); } else error ("Cell::column: requires 2-D cell array");