[LLVMbugs] [Bug 20611] New: crash with lambda (auto) return type

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sun Aug 10 07:44:54 PDT 2014


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

            Bug ID: 20611
           Summary: crash with lambda (auto) return type
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++1y
          Assignee: unassignedclangbugs at nondot.org
          Reporter: grish.vanika at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

This simple piece of code compiled fine:
    auto l = [](auto& container) -> auto {
            return container[0];
        };

    std::vector<int> v{ 1, 2, 3 };
    std::cout << l(v);

But clang will crash on this:
    auto l = [](auto& container) -> (auto) {
            return container[0];
        };

    std::vector<int> v{ 1, 2, 3 };
    std::cout << l(v);

Here is additional brackets around auto: (auto).

Thanks

-- 
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/20140810/506fc590/attachment.html>


More information about the llvm-bugs mailing list