[LLVMbugs] [Bug 16907] New: Crash in lambda expression

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Aug 15 20:29:46 PDT 2013


http://llvm.org/bugs/show_bug.cgi?id=16907

            Bug ID: 16907
           Summary: Crash in lambda expression
           Product: clang
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++11
          Assignee: unassignedclangbugs at nondot.org
          Reporter: fimbul77 at gmail.com
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Following the code : 

#include <iostream>

int main()
{
    auto f = []() {
        static int x = 0;
        return [&]() -> void {
            ++x;
            std::cout << x << std::endl;
        };
    }();

    f();
}

f() makes clang crash.

Wandbox
http://melpon.org/wandbox/permlink/FdYNYlKE0UzH7ZM5

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20130816/4c195ac8/attachment.html>


More information about the llvm-bugs mailing list