Line
Link Here
|
0 |
-- doc/interpreter/munge-texi.cc |
0 |
++ doc/interpreter/munge-texi.cc |
Lines 29-34
Link Here
|
29 |
#include <iostream> |
29 |
#include <iostream> |
30 |
#include <fstream> |
30 |
#include <fstream> |
31 |
#include <string> |
31 |
#include <string> |
|
|
32 |
#include <cstring> |
33 |
#include <cstdlib> |
32 |
#include <map> |
34 |
#include <map> |
33 |
|
35 |
|
34 |
static const char doc_delim = ''; |
36 |
static const char doc_delim = ''; |
35 |
-- liboctave/chMatrix.cc |
37 |
++ liboctave/chMatrix.cc |
Lines 32-37
Link Here
|
32 |
|
32 |
|
33 |
#include <iostream> |
33 |
#include <iostream> |
34 |
#include <string> |
34 |
#include <string> |
|
|
35 |
#include <cstring> |
35 |
|
36 |
|
36 |
#include "lo-error.h" |
37 |
#include "lo-error.h" |
37 |
#include "str-vec.h" |
38 |
#include "str-vec.h" |
38 |
-- liboctave/data-conv.cc |
39 |
++ liboctave/data-conv.cc |
Lines 28-33
Link Here
|
28 |
#include <cctype> |
28 |
#include <cctype> |
29 |
|
29 |
|
30 |
#include <iostream> |
30 |
#include <iostream> |
|
|
31 |
#include <cstdlib> |
31 |
|
32 |
|
32 |
#include "byte-swap.h" |
33 |
#include "byte-swap.h" |
33 |
#include "data-conv.h" |
34 |
#include "data-conv.h" |
34 |
-- liboctave/lo-sysdep.cc |
35 |
++ liboctave/lo-sysdep.cc |
Lines 27-32
Link Here
|
27 |
|
27 |
|
28 |
#include <iostream> |
28 |
#include <iostream> |
29 |
#include <string> |
29 |
#include <string> |
|
|
30 |
#include <cstring> |
30 |
|
31 |
|
31 |
#ifdef HAVE_UNISTD_H |
32 |
#ifdef HAVE_UNISTD_H |
32 |
#ifdef HAVE_SYS_TYPES_H |
33 |
#ifdef HAVE_SYS_TYPES_H |
33 |
-- liboctave/lo-utils.cc |
34 |
++ liboctave/lo-utils.cc |
Lines 31-36
Link Here
|
31 |
#include <cstdio> |
31 |
#include <cstdio> |
32 |
|
32 |
|
33 |
#include <string> |
33 |
#include <string> |
|
|
34 |
#include <cstring> |
34 |
|
35 |
|
35 |
#ifdef HAVE_UNISTD_H |
36 |
#ifdef HAVE_UNISTD_H |
36 |
#ifdef HAVE_SYS_TYPES_H |
37 |
#ifdef HAVE_SYS_TYPES_H |
37 |
-- liboctave/oct-env.cc |
38 |
++ liboctave/oct-env.cc |
Lines 45-50
Link Here
|
45 |
#include <cstdlib> |
45 |
#include <cstdlib> |
46 |
|
46 |
|
47 |
#include <string> |
47 |
#include <string> |
|
|
48 |
#include <cstring> |
48 |
|
49 |
|
49 |
#ifdef HAVE_UNISTD_H |
50 |
#ifdef HAVE_UNISTD_H |
50 |
#ifdef HAVE_SYS_TYPES_H |
51 |
#ifdef HAVE_SYS_TYPES_H |
51 |
-- liboctave/oct-sort.cc |
52 |
++ liboctave/oct-sort.cc |
Lines 84-89
Link Here
|
84 |
#include <config.h> |
84 |
#include <config.h> |
85 |
#endif |
85 |
#endif |
86 |
|
86 |
|
|
|
87 |
#include <cstdlib> |
88 |
#include <cstring> |
89 |
|
87 |
#include "lo-mappers.h" |
90 |
#include "lo-mappers.h" |
88 |
#include "quit.h" |
91 |
#include "quit.h" |
89 |
#include "oct-sort.h" |
92 |
#include "oct-sort.h" |
90 |
-- src/DLD-FUNCTIONS/sort.cc |
93 |
++ src/DLD-FUNCTIONS/sort.cc |
Lines 294-300
Link Here
|
294 |
template class octave_sort<vec_index<unsigned EIGHT_BYTE_INT> *>; |
294 |
template class octave_sort<vec_index<unsigned EIGHT_BYTE_INT> *>; |
295 |
|
295 |
|
296 |
template <> |
296 |
template <> |
297 |
static octave_value |
297 |
octave_value |
298 |
mx_sort (ArrayN<double> &m, int dim, sortmode mode) |
298 |
mx_sort (ArrayN<double> &m, int dim, sortmode mode) |
299 |
{ |
299 |
{ |
300 |
octave_value retval; |
300 |
octave_value retval; |
Lines 345-355
Link Here
|
345 |
// things up. |
345 |
// things up. |
346 |
|
346 |
|
347 |
if (lo_ieee_signbit (octave_NaN)) |
347 |
if (lo_ieee_signbit (octave_NaN)) |
|
|
348 |
{ |
348 |
if (mode == UNDEFINED || mode == ASCENDING) |
349 |
if (mode == UNDEFINED || mode == ASCENDING) |
349 |
{ |
350 |
{ |
350 |
unsigned int i = 0; |
351 |
unsigned int i = 0; |
351 |
double *vtmp = (double *)p; |
352 |
double *vtmp = (double *)p; |
352 |
while (xisnan (vtmp[i++]) && i < ns); |
353 |
while (xisnan (vtmp[i++]) && i < ns) {} |
353 |
for (unsigned int l = 0; l < ns - i + 1; l++) |
354 |
for (unsigned int l = 0; l < ns - i + 1; l++) |
354 |
vtmp[l] = vtmp[l+i-1]; |
355 |
vtmp[l] = vtmp[l+i-1]; |
355 |
for (unsigned int l = ns - i + 1; l < ns; l++) |
356 |
for (unsigned int l = ns - i + 1; l < ns; l++) |
Lines 359-370
Link Here
|
359 |
{ |
360 |
{ |
360 |
unsigned int i = ns; |
361 |
unsigned int i = ns; |
361 |
double *vtmp = (double *)p; |
362 |
double *vtmp = (double *)p; |
362 |
while (xisnan (vtmp[--i]) && i > 0); |
363 |
while (xisnan (vtmp[--i]) && i > 0) {} |
363 |
for (int l = i; l >= 0; l--) |
364 |
for (int l = i; l >= 0; l--) |
364 |
vtmp[l-i+ns-1] = vtmp[l]; |
365 |
vtmp[l-i+ns-1] = vtmp[l]; |
365 |
for (unsigned int l = 0; l < ns - i - 1; l++) |
366 |
for (unsigned int l = 0; l < ns - i - 1; l++) |
366 |
vtmp[l] = octave_NaN; |
367 |
vtmp[l] = octave_NaN; |
367 |
} |
368 |
} |
|
|
369 |
} |
368 |
|
370 |
|
369 |
p += ns; |
371 |
p += ns; |
370 |
} |
372 |
} |
Lines 404-413
Link Here
|
404 |
// fix things up. |
406 |
// fix things up. |
405 |
|
407 |
|
406 |
if (lo_ieee_signbit (octave_NaN)) |
408 |
if (lo_ieee_signbit (octave_NaN)) |
|
|
409 |
{ |
407 |
if (mode == UNDEFINED || mode == ASCENDING) |
410 |
if (mode == UNDEFINED || mode == ASCENDING) |
408 |
{ |
411 |
{ |
409 |
unsigned int i = 0; |
412 |
unsigned int i = 0; |
410 |
while (xisnan (v[i++*stride + offset]) && i < ns); |
413 |
while (xisnan (v[i++*stride + offset]) && i < ns) {} |
411 |
for (unsigned int l = 0; l < ns - i + 1; l++) |
414 |
for (unsigned int l = 0; l < ns - i + 1; l++) |
412 |
v[l*stride + offset] = v[(l+i-1)*stride + offset]; |
415 |
v[l*stride + offset] = v[(l+i-1)*stride + offset]; |
413 |
for (unsigned int l = ns - i + 1; l < ns; l++) |
416 |
for (unsigned int l = ns - i + 1; l < ns; l++) |
Lines 416-427
Link Here
|
416 |
else |
419 |
else |
417 |
{ |
420 |
{ |
418 |
unsigned int i = ns; |
421 |
unsigned int i = ns; |
419 |
while (xisnan (v[--i*stride + offset]) && i > 0); |
422 |
while (xisnan (v[--i*stride + offset]) && i > 0) {} |
420 |
for (int l = i; l >= 0; l--) |
423 |
for (int l = i; l >= 0; l--) |
421 |
v[(l-i+ns-1)*stride + offset] = v[l*stride + offset]; |
424 |
v[(l-i+ns-1)*stride + offset] = v[l*stride + offset]; |
422 |
for (unsigned int l = 0; l < ns - i - 1; l++) |
425 |
for (unsigned int l = 0; l < ns - i - 1; l++) |
423 |
v[l*stride + offset] = octave_NaN; |
426 |
v[l*stride + offset] = octave_NaN; |
424 |
} |
427 |
} |
|
|
428 |
} |
425 |
} |
429 |
} |
426 |
} |
430 |
} |
427 |
|
431 |
|
Lines 431-437
Link Here
|
431 |
} |
435 |
} |
432 |
|
436 |
|
433 |
template <> |
437 |
template <> |
434 |
static octave_value_list |
438 |
octave_value_list |
435 |
mx_sort_indexed (ArrayN<double> &m, int dim, sortmode mode) |
439 |
mx_sort_indexed (ArrayN<double> &m, int dim, sortmode mode) |
436 |
{ |
440 |
{ |
437 |
octave_value_list retval; |
441 |
octave_value_list retval; |
Lines 506-515
Link Here
|
506 |
// If it will be sorted to the beginning, fix things up. |
510 |
// If it will be sorted to the beginning, fix things up. |
507 |
|
511 |
|
508 |
if (lo_ieee_signbit (octave_NaN)) |
512 |
if (lo_ieee_signbit (octave_NaN)) |
|
|
513 |
{ |
509 |
if (mode == UNDEFINED || mode == ASCENDING) |
514 |
if (mode == UNDEFINED || mode == ASCENDING) |
510 |
{ |
515 |
{ |
511 |
unsigned int i = 0; |
516 |
unsigned int i = 0; |
512 |
while (xisnan (v[i++*stride+offset]) && i < ns); |
517 |
while (xisnan (v[i++*stride+offset]) && i < ns) {} |
513 |
OCTAVE_LOCAL_BUFFER (double, itmp, i - 1); |
518 |
OCTAVE_LOCAL_BUFFER (double, itmp, i - 1); |
514 |
for (unsigned int l = 0; l < i -1; l++) |
519 |
for (unsigned int l = 0; l < i -1; l++) |
515 |
itmp[l] = idx(l*stride + offset); |
520 |
itmp[l] = idx(l*stride + offset); |
Lines 527-533
Link Here
|
527 |
else |
532 |
else |
528 |
{ |
533 |
{ |
529 |
unsigned int i = ns; |
534 |
unsigned int i = ns; |
530 |
while (xisnan (v[--i*stride+offset]) && i > 0); |
535 |
while (xisnan (v[--i*stride+offset]) && i > 0) {} |
531 |
OCTAVE_LOCAL_BUFFER (double, itmp, ns - i - 1); |
536 |
OCTAVE_LOCAL_BUFFER (double, itmp, ns - i - 1); |
532 |
for (unsigned int l = 0; l < ns - i -1; l++) |
537 |
for (unsigned int l = 0; l < ns - i -1; l++) |
533 |
itmp[l] = idx((l+i+1)*stride + offset); |
538 |
itmp[l] = idx((l+i+1)*stride + offset); |
Lines 542-547
Link Here
|
542 |
idx(l*stride + offset) = itmp[k]; |
547 |
idx(l*stride + offset) = itmp[k]; |
543 |
} |
548 |
} |
544 |
} |
549 |
} |
|
|
550 |
} |
545 |
} |
551 |
} |
546 |
|
552 |
|
547 |
retval(1) = idx; |
553 |
retval(1) = idx; |
548 |
-- src/file-io.cc |
554 |
++ src/file-io.cc |
Lines 42-47
Link Here
|
42 |
#include <cerrno> |
42 |
#include <cerrno> |
43 |
#include <climits> |
43 |
#include <climits> |
44 |
#include <cstdio> |
44 |
#include <cstdio> |
|
|
45 |
#include <cstring> |
45 |
|
46 |
|
46 |
#include <iostream> |
47 |
#include <iostream> |
47 |
#include <vector> |
48 |
#include <vector> |
48 |
-- src/oct-stream.cc |
49 |
++ src/oct-stream.cc |
Lines 1255-1261
Link Here
|
1255 |
int c3 = is.get (); |
1255 |
int c3 = is.get (); |
1256 |
|
1256 |
|
1257 |
if (c3 != EOF) |
1257 |
if (c3 != EOF) |
1258 |
|
1258 |
{ |
1259 |
if (c3 == 'f') |
1259 |
if (c3 == 'f') |
1260 |
{ |
1260 |
{ |
1261 |
int c4 = is.get (); |
1261 |
int c4 = is.get (); |
Lines 1290-1295
Link Here
|
1290 |
|
1290 |
|
1291 |
is >> ref; |
1291 |
is >> ref; |
1292 |
} |
1292 |
} |
|
|
1293 |
} |
1293 |
} |
1294 |
} |
1294 |
else |
1295 |
else |
1295 |
{ |
1296 |
{ |
1296 |
-- src/ov-fcn-inline.cc |
1297 |
++ src/ov-fcn-inline.cc |
Lines 126-132
Link Here
|
126 |
OSSTREAM buf; |
126 |
OSSTREAM buf; |
127 |
|
127 |
|
128 |
// Skip preceeding newline(s) |
128 |
// Skip preceeding newline(s) |
129 |
while (is.get (c) && c == '\n'); |
129 |
while (is.get (c) && c == '\n') {} |
130 |
|
130 |
|
131 |
if (is) |
131 |
if (is) |
132 |
{ |
132 |
{ |
133 |
-- src/parse.y |
133 |
++ src/parse.y |
Lines 34-39
Link Here
|
34 |
|
34 |
|
35 |
#include <cassert> |
35 |
#include <cassert> |
36 |
#include <cstdio> |
36 |
#include <cstdio> |
|
|
37 |
#include <cstring> |
37 |
|
38 |
|
38 |
#ifdef YYBYACC |
39 |
#ifdef YYBYACC |
39 |
#include <cstdlib> |
40 |
#include <cstdlib> |
40 |
-- src/pr-output.cc |
41 |
++ src/pr-output.cc |
Lines 1602-1608
Link Here
|
1602 |
} |
1602 |
} |
1603 |
|
1603 |
|
1604 |
template <> |
1604 |
template <> |
1605 |
static inline void |
1605 |
inline void |
1606 |
pr_plus_format (std::ostream& os, const Complex& c) |
1606 |
pr_plus_format (std::ostream& os, const Complex& c) |
1607 |
{ |
1607 |
{ |
1608 |
double rp = c.real (); |
1608 |
double rp = c.real (); |
1609 |
-- src/unwind-prot.cc |
1609 |
++ src/unwind-prot.cc |
Lines 30-35
Link Here
|
30 |
#endif |
30 |
#endif |
31 |
|
31 |
|
32 |
#include <cstddef> |
32 |
#include <cstddef> |
|
|
33 |
#include <cstring> |
33 |
|
34 |
|
34 |
#include "CMatrix.h" |
35 |
#include "CMatrix.h" |
35 |
|
36 |
|