Mercurial > hg > octave-nkf
changeset 18293:7e297c293e4c gui-release
Fix pretty printing with debug prompt (bug #41204).
* pt-pr-code.cc (tree_print_code::newline): Add call to indent() to print
prefix for blank lines.
* pt-pr-code.cc (tree_print_code::print_comment_elt): Add call to indent() to
print prefix before comment lines.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Mon, 13 Jan 2014 10:48:05 -0800 |
parents | bc139ccccef9 |
children | f227bb47314f |
files | libinterp/parse-tree/pt-pr-code.cc |
diffstat | 1 files changed, 10 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/libinterp/parse-tree/pt-pr-code.cc +++ b/libinterp/parse-tree/pt-pr-code.cc @@ -1218,6 +1218,9 @@ os << alt_txt; else { + // Print prefix for blank lines. + indent (); + os << "\n"; beginning_of_line = true; @@ -1268,7 +1271,13 @@ if (c == '\n') { if (prev_char_was_newline) - os << "##"; + { + printed_something = true; + + indent (); + + os << "##"; + } newline ();