================
@@ -11591,6 +11591,10 @@ def err_conflicting_aligned_options : Error <
 def err_coro_invalid_addr_of_label : Error<
   "the GNU address of label extension is not allowed in coroutines."
 >;
+def err_coroutine_return_type : Error<
+  "function returns a coroutine return type %0 but is neither a coroutine nor 
a coroutine wrapper; "
----------------
ilya-biryukov wrote:

NIT: should we mention the name of the `[[clang::coro_return_type]]` here?
'Coroutine return type' resembles the C++ standard a bit too too much, I am 
afraid this might cause confusion and people looking in the standard. Marking 
it clear this is an extension is probably useful here.

E.g. we could add a note that adds the context:
```note: class 'Gen' has been marked with [[clang::coro_return_type]] here```
or add this to an error message 
```error: function returns a type %0 marked with [[clang::coro_return_type]]```


https://github.com/llvm/llvm-project/pull/71945
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to