comparison src/pr-output.cc @ 2664:9ccca1037db3

[project @ 1997-02-08 23:17:04 by jwe]
author jwe
date Sat, 08 Feb 1997 23:17:05 +0000
parents 3723512a827a
children 9aeba8e006a4
comparison
equal deleted inserted replaced
2663:00b2eff19bf5 2664:9ccca1037db3
1487 int nstr = chm.rows (); 1487 int nstr = chm.rows ();
1488 1488
1489 if (pr_as_read_syntax && nstr > 1) 1489 if (pr_as_read_syntax && nstr > 1)
1490 os << "[ "; 1490 os << "[ ";
1491 1491
1492 for (int i = 0; i < nstr; i++) 1492 if (nstr == 0)
1493 { 1493 os << "\n";
1494 string row = chm.row_as_string (i); 1494 else
1495 1495 {
1496 if (pr_as_read_syntax) 1496 for (int i = 0; i < nstr; i++)
1497 { 1497 {
1498 os << "\"" << undo_string_escapes (row) << "\""; 1498 string row = chm.row_as_string (i);
1499 1499
1500 if (i < nstr - 1) 1500 if (pr_as_read_syntax)
1501 os << "; "; 1501 {
1502 os << "\"" << undo_string_escapes (row) << "\"";
1503
1504 if (i < nstr - 1)
1505 os << "; ";
1506 }
1507 else
1508 os << row << "\n";
1502 } 1509 }
1503 else
1504 os << row << "\n";
1505 } 1510 }
1506 1511
1507 if (pr_as_read_syntax && nstr > 1) 1512 if (pr_as_read_syntax && nstr > 1)
1508 os << " ]"; 1513 os << " ]";
1509 } 1514 }