http://d.puremagic.com/issues/show_bug.cgi?id=9059

           Summary: No exception runtime error message with missing file +
                    byLine
           Product: D
           Version: D2
          Platform: x86
        OS/Version: Windows
            Status: NEW
          Keywords: diagnostic
          Severity: normal
          Priority: P2
         Component: druntime
        AssignedTo: nob...@puremagic.com
        ReportedBy: bearophile_h...@eml.cc


--- Comment #0 from bearophile_h...@eml.cc 2012-11-22 15:46:02 PST ---
import std.stdio: File;
void main() {
    auto f = File("missing").byLine();
}



If I compile and run this program with dmd 2.061alpha with "-g" it correctly
gives a stack trace (with no line numbers):

dmd -g -run test.d

std.exception.ErrnoException@std\stdio.d(315): Cannot open file `missing' in
mode `rb' (No such file or direct
ory)
----------------
0x00412F44 in char[][] core.sys.windows.stacktrace.StackTrace.trace()
0x00412DCF in core.sys.windows.stacktrace.StackTrace
core.sys.windows.stacktrace.StackTrace.__ctor()
0x00404D2F in
D3std9exception80__T12errnoEnforceTPOS4core4Çâ¬c5Ôio6_+bufVAyaa11_7374645c²696f2e¨Vk315ZÇÄ-FÇÜ-L
Çâ-ZÇ܃
0x004045DC in extern (C) int rt.dmain2._d_run_main(int, char**, extern (C) int
function(char[][])*).void runMa
in()
0x00404612 in extern (C) int rt.dmain2._d_run_main(int, char**, extern (C) int
function(char[][])*).void runAl
l()
0x00404229 in _d_run_main
0x00402D04 in main
0x7782D309 in BaseThreadInitThunk
0x77A51603 in RtlInitializeExceptionChain
0x77A515D6 in RtlInitializeExceptionChain
----------------


If I compile and run it without "-g" (dmd -run test.d) it doesn't show the
std.exception.ErrnoException, and the program just crashes with no error
messages at run-time.

Maybe this is a regression.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to