[clang] [clang/APINotes] Fix assertion crash in addObjCMethod for protocol DesignatedInit methods (PR #183799)

Gábor Horváth via cfe-commits cfe-commits at lists.llvm.org
Fri Feb 27 10:58:52 PST 2026


================
@@ -0,0 +1,15 @@
+// RUN: rm -rf %t && mkdir -p %t
+// RUN: %clang_cc1 -fmodules -fimplicit-module-maps -fmodules-cache-path=%t/ModulesCache -fapinotes-modules -Wno-private-module -fsyntax-only -I %S/Inputs/Headers -F %S/Inputs/Frameworks %s -verify
+
+// Regression test for APINotesWriter::addObjCMethod asserting when a protocol
----------------
Xazax-hun wrote:

Could we dump the AST and add a FileCheck to make sure the attribute is properly applied? The other APINotes tests should have some examples.

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


More information about the cfe-commits mailing list