https://bugs.llvm.org/show_bug.cgi?id=34983
Bug ID: 34983
Summary: [coroutines] diagnostics for missing coroutine promise
members produce invalid typo corrections
Product: clang
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: C++
Assignee: unassignedclangb...@nondot.org
Reporter: richard-l...@metafoo.co.uk
CC: dgre...@apple.com, gornisha...@gmail.com,
llvm-bugs@lists.llvm.org
Testcase:
#include <experimental/coroutine>
namespace std { using namespace std::experimental; }
struct corotype {
struct promise_type {
std::suspend_always initial_suspend();
};
};
static corotype f() {
}
void h();
corotype g() {
auto a = f();
while (co_await a) h();
}
Produces this wrong typo correction:
<stdin>:12:10: error: no member named 'final_suspend' in
'corotype::promise_type'; did you mean 'initial_suspend'?
corotype g() {
^
initial_suspend
<stdin>:6:25: note: 'initial_suspend' declared here
std::suspend_always initial_suspend();
^
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs