[clang] [WebKit checkers] Add an annotation for pointer conversion. (PR #141277)

Ryosuke Niwa via cfe-commits cfe-commits at lists.llvm.org
Fri Jun 6 13:41:22 PDT 2025


================
@@ -44,6 +43,12 @@ inline Target* uncheckedDowncast(Source* source)
     return static_cast<Target*>(source);
 }
 
+template<typename Target, typename Source>
+Target* [[clang::annotate_type("webkit.pointerconversion")]] newCastFunction(Source*);
----------------
rniwa wrote:

I don't think so. I added a test case for that.

https://github.com/llvm/llvm-project/pull/141277


More information about the cfe-commits mailing list