[LLVMbugs] [Bug 6477] New: Goto over object definition causes build error

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Wed Mar 3 06:46:12 PST 2010


           Summary: Goto over object definition causes build error
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P5
         Component: -New Bugs
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: jpakkane at gmail.com
                CC: llvmbugs at cs.uiuc.edu

When you compile the attached file with clang++, it gives this error:

gototest.cxx:5:5: error: illegal goto into protected scope
    goto ED_END;
gototest.cxx:6:18: note: jump bypasses variable initialization
    std::fstream f;

If you comment out line 6, everything works.

This is a regression, as svn checkout from a couple of days ago worked just
fine. The same code compiles on g++ and MSVC without errors.

Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

More information about the llvm-bugs mailing list