================
@@ -34,7 +51,11 @@ const MyObj &S::both(
template <class T>
struct MixedSpecializations {
T data;
- T &both(T &arg, bool); // expected-warning 2 {{'lifetimebound' attribute on
this definition is not visible to callers before the definition; add it to the
declaration instead}}
+ T &both(T & // expected-warning {{'lifetimebound' attribute on this
definition is not visible to callers before the definition; add it to the
declaration instead}}
+ arg, // CHECK-DAG:
fix-it:"{{.*}}":{[[@LINE]]:{{[0-9]+}}-[[@LINE]]:{{[0-9]+}}}:"
{{\[\[clang::lifetimebound\]\]}}"
----------------
usx95 wrote:
For a separate PR:
We highlight the complete param declaration but attach the warning to the
beginning. It would make sense to attach the text to the place where
lifetimebound will go here. This would match the fixit and warning location
here.
https://godbolt.org/z/Pb9zjG6nx
https://github.com/llvm/llvm-project/pull/199149
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits