mirror of
https://github.com/denoland/deno.git
synced 2025-09-27 04:39:10 +00:00
refactor(cli/fmt_errors): Format stack frames in prepareStackTrace() (#4706)
This commit is contained in:
parent
2feb661b85
commit
2b362bef85
25 changed files with 224 additions and 427 deletions
10
cli/tests/error_019_stack_function.ts
Normal file
10
cli/tests/error_019_stack_function.ts
Normal file
|
@ -0,0 +1,10 @@
|
|||
function foo(): never {
|
||||
throw new Error("function");
|
||||
}
|
||||
|
||||
try {
|
||||
foo();
|
||||
} catch (error) {
|
||||
console.log(error.stack);
|
||||
throw error;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue