-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* reffs #3169 initial new stack handling * refs #3169 progress on unified thread and exception stack trace support * reffs #3169 removed lots of old code related to the old optional call stack implementation; the HAVE_RUNTIME_THREAD_STACK_TRACE constant is always True, removed associated build options and internal logic * refs #3169 fixed deadlock in thread stack retrieval * refs #3169 new stack trace API updates * refs #3177 fixed binary module installation with autotools * refs #3179 std::string COW issue workaround (#3180) * reffs #3169 removed lots of old code related to the old optional call stack implementation; the HAVE_RUNTIME_THREAD_STACK_TRACE constant is always True, removed associated build options and internal logic * refs #3169 new stack trace API updates * refs #3169 finalized the API and fixed C++ issues * refs #3169 refactored default exception handling & warning output, added language info to exceptions, updates tests and docs * refs #3169 fixed test * refs #3169 more API updates * refs #3169 fixed dbg stmt * refs #3169 show builtin code location properly in call & exception stacks
- Loading branch information
Showing
32 changed files
with
1,784 additions
and
1,459 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
#!/usr/bin/env qore | ||
# -*- mode: qore; indent-tabs-mode: nil -*- | ||
|
||
%new-style | ||
%enable-all-warnings | ||
%require-types | ||
%strict-args | ||
|
||
%requires ../../../../qlib/Util.qm | ||
%requires ../../../../qlib/QUnit.qm | ||
|
||
%exec-class GetExceptionString | ||
|
||
public class GetExceptionString inherits QUnit::Test { | ||
constructor() : Test("GetExceptionString", "1.0") { | ||
addTestCase("get_exception_string()", \testGetExceptionString()); | ||
|
||
set_return_value(main()); | ||
} | ||
|
||
testGetExceptionString() { | ||
hash<ExceptionInfo> ex; | ||
try { | ||
throw "ERR", "err"; | ||
} catch (hash<ExceptionInfo> ex1) { | ||
ex = ex1; | ||
} | ||
assertEq("Qore", ex.callstack[0].lang); | ||
assertEq("GetExceptionString::constructor", ex.callstack.last().function); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
#!/usr/bin/env qore | ||
# -*- mode: qore; indent-tabs-mode: nil -*- | ||
|
||
%new-style | ||
%enable-all-warnings | ||
%require-types | ||
%strict-args | ||
|
||
%requires ../../../../qlib/QUnit.qm | ||
|
||
%exec-class GetExPosTest | ||
|
||
public class GetExPosTest inherits QUnit::Test { | ||
constructor() : Test("GetExPosTest", "1.0") { | ||
addTestCase("get_ex_pos() test", \getExPosTest()); | ||
|
||
# Return for compatibility with test harness that checks return value. | ||
set_return_value(main()); | ||
} | ||
|
||
getExPosTest() { | ||
try { | ||
if (True) { | ||
throw "ERR", "desc"; | ||
} | ||
assertTrue(False); | ||
} catch (hash<ExceptionInfo> ex) { | ||
string str = get_ex_pos(ex); | ||
assertRegex("get_ex_pos.qtest:24 \\(Qore\\)$", str); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.