Mercurial > hg > octave-lyh
comparison liboctave/Array.cc @ 10610:f5f6bde82e19
fix null assignment bug #29785
author | Jaroslav Hajek <highegg@gmail.com> |
---|---|
date | Thu, 06 May 2010 14:47:27 +0200 |
parents | 3f973f6c841c |
children | c170eb1c067f |
comparison
equal
deleted
inserted
replaced
10609:58bcda68ac11 | 10610:f5f6bde82e19 |
---|---|
1417 if (i.extent (n) != n) | 1417 if (i.extent (n) != n) |
1418 gripe_del_index_out_of_range (true, i.extent (n), n); | 1418 gripe_del_index_out_of_range (true, i.extent (n), n); |
1419 | 1419 |
1420 octave_idx_type l, u; | 1420 octave_idx_type l, u; |
1421 bool col_vec = ndims () == 2 && columns () == 1 && rows () != 1; | 1421 bool col_vec = ndims () == 2 && columns () == 1 && rows () != 1; |
1422 if (i.is_scalar () && i(0) == n-1) | 1422 if (i.is_scalar () && i(0) == n-1 && dimensions.is_vector ()) |
1423 { | 1423 { |
1424 // Stack "pop" operation. | 1424 // Stack "pop" operation. |
1425 resize1 (n-1); | 1425 resize1 (n-1); |
1426 } | 1426 } |
1427 else if (i.is_cont_range (n, l, u)) | 1427 else if (i.is_cont_range (n, l, u)) |