https://llvm.org/bugs/show_bug.cgi?id=22998

            Bug ID: 22998
           Summary: delayed typo correction crash around C++14 generic
                    lambdas in -std=c++03
           Product: clang
           Version: unspecified
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: Frontend
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected], [email protected]
    Classification: Unclassified

$ cat t.cpp
template <typename F> decltype(auto) deduce(F f) {
  return &decltype(f)::operator();
}

template <typename C, typename R, typename A>
decltype(auto) signaturehelper(R (C::*f)(A) const) {
  return R();
}

int main() {
  auto l = [](int x) { return x * 2; };
  decltype(signaturehelper(deduce(l))) p;
}

$ clang -cc1 t.cpp
... cascading errors due to lack of -std=c++14
Assertion failed: DelayedTypos.empty() && "Uncorrected typos!", file
..\tools\clang\lib\Sema\Sema.cpp, line 273

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to