diff -r 35f9ffb13fd6 libinterp/corefcn/pr-output.cc --- a/libinterp/corefcn/pr-output.cc Wed Oct 23 12:50:42 2019 -0700 +++ b/libinterp/corefcn/pr-output.cc Wed Oct 23 13:57:24 2019 -0700 @@ -2642,14 +2642,14 @@ octave_print_internal (std::ostream& os, if (pr_as_read_syntax) { - os << '"' << octave::undo_string_escapes (row) << '"'; + os << '\'' << octave::undo_string_escapes (row) << '\''; if (i < nstr - 1) os << "; "; } else { - os << row; + os << '\'' << row << '\''; if (i < nstr - 1) os << "\n";