0
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2025-03-03 17:34:47 -05:00

fix(cli/repl): format evaluation results with the object specifier (#7561)

This commit is contained in:
Casper Beyer 2020-09-19 00:47:08 +08:00 committed by GitHub
parent 8edf099485
commit de95fbebc4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -63,7 +63,7 @@
? undefined ? undefined
: result; : result;
if (!isCloseCalled()) { if (!isCloseCalled()) {
replLog(lastEvalResult); replLog("%o", lastEvalResult);
} }
} else if (errInfo.isCompileError && isRecoverableError(errInfo.thrown)) { } else if (errInfo.isCompileError && isRecoverableError(errInfo.thrown)) {
// Recoverable compiler error // Recoverable compiler error

View file

@ -1053,7 +1053,7 @@ fn repl_test_console_log() {
Some(vec![("NO_COLOR".to_owned(), "1".to_owned())]), Some(vec![("NO_COLOR".to_owned(), "1".to_owned())]),
false, false,
); );
assert!(out.ends_with("hello\nundefined\nworld\n")); assert!(out.ends_with("hello\nundefined\n\"world\"\n"));
assert!(err.is_empty()); assert!(err.is_empty());
} }