Print exception hint in the debugger client when an exception is thrown. (#1841)
JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg.u-szeged@partner.samsung.com
This commit is contained in:
@@ -1,2 +1,5 @@
|
||||
c
|
||||
c
|
||||
c
|
||||
c
|
||||
quit
|
||||
|
||||
@@ -2,5 +2,18 @@ Connecting to: localhost:5001
|
||||
Stopped at tests/debugger/do_exception.js:15
|
||||
(jerry-debugger) c
|
||||
Exception throw detected (to disable automatic stop type exception 0)
|
||||
Stopped at tests/debugger/do_exception.js:19 (in foo() at line:17, col:1)
|
||||
Exception hint: TypeError
|
||||
Stopped around tests/debugger/do_exception.js:19 (in foo() at line:17, col:1)
|
||||
(jerry-debugger) c
|
||||
Exception throw detected (to disable automatic stop type exception 0)
|
||||
Exception hint: ReferenceError
|
||||
Stopped at tests/debugger/do_exception.js:24 (in foo() at line:17, col:1)
|
||||
(jerry-debugger) c
|
||||
Exception throw detected (to disable automatic stop type exception 0)
|
||||
Exception hint: 456
|
||||
Stopped at tests/debugger/do_exception.js:29 (in foo() at line:17, col:1)
|
||||
(jerry-debugger) c
|
||||
Exception throw detected (to disable automatic stop type exception 0)
|
||||
Exception hint: RangeError: Bad range!
|
||||
Stopped around tests/debugger/do_exception.js:34 (in foo() at line:17, col:1)
|
||||
(jerry-debugger) quit
|
||||
|
||||
@@ -15,11 +15,25 @@
|
||||
print("exception handler configuration test")
|
||||
|
||||
function foo() {
|
||||
try {
|
||||
b = a / c;
|
||||
} catch (e) {
|
||||
print(e); // pass exception object to err handler
|
||||
}
|
||||
try {
|
||||
undefined();
|
||||
} catch (e) {
|
||||
}
|
||||
|
||||
try {
|
||||
xxx();
|
||||
} catch (e) {
|
||||
}
|
||||
|
||||
try {
|
||||
throw 456;
|
||||
} catch (e) {
|
||||
}
|
||||
|
||||
try {
|
||||
throw new RangeError("Bad range!");
|
||||
} catch (e) {
|
||||
}
|
||||
}
|
||||
|
||||
foo()
|
||||
|
||||
Reference in New Issue
Block a user