May 25, 2010 [dmd-internals] druntime + test suite issues | ||||
---|---|---|---|---|
| ||||
The new druntime defaults to adding stack traces to exceptions now, which causes one test in the test suite to fail due to checking for an exact match in the exception string. Luckily it's easy enough to disable the handler: diff --git a/testformat.d b/testformat.d index 0a291d5..a6f8546 100644 --- a/testformat.d +++ b/testformat.d @@ -1,4 +1,5 @@ +import core.runtime; import std.stdio; import std.string; @@ -76,6 +77,10 @@ void test2() void test3() { + //auto oldTH = Runtime.traceHandler; + Runtime.traceHandler = null; + //scope(exit) Runtime.traceHandler = oldTH; + Object e = new Exception("hello"); writeln(e.toString()); assert(e.toString() == "object.Exception: hello"); See my latest comment to bug 1001 for the code to allow the two commented out lines. Later, Brad |
May 25, 2010 [dmd-internals] druntime + test suite issues | ||||
---|---|---|---|---|
| ||||
Posted in reply to Brad Roberts | On Tue, May 25, 2010 at 11:28 AM, Brad Roberts <braddr at puremagic.com> wrote: > See my latest comment to bug 1001 for the code to allow the two commented out lines. > http://d.puremagic.com/issues/show_bug.cgi?id=1001#c19 |
Copyright © 1999-2021 by the D Language Foundation