llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT--> @llvm/pr-subscribers-clang Author: Nick Sarnie (sarnex) <details> <summary>Changes</summary> I didn't add a test because this can't be reproduced yet in this repo, I reproduced this only in intel's fork with more SYCL support. I also fixed some formatting. --- Full diff: https://github.com/llvm/llvm-project/pull/143546.diff 1 Files Affected: - (modified) clang/include/clang/Basic/Attr.td (+3-3) ``````````diff diff --git a/clang/include/clang/Basic/Attr.td b/clang/include/clang/Basic/Attr.td index f889e41c8699f..82861a3d618d9 100644 --- a/clang/include/clang/Basic/Attr.td +++ b/clang/include/clang/Basic/Attr.td @@ -1590,11 +1590,11 @@ def DeviceKernel : DeclOrTypeAttr { // list, but here we have the same spelling with unscores and without, // so handle that case manually. return A.getAttributeSpellingListIndex() == Keyword_kernel || - A.getAttrName()->getName() == "kernel"; + (A.getAttrName() && A.getAttrName()->getName() == "kernel"); } static inline bool isOpenCLSpelling(const AttributeCommonInfo* A) { - if (!A) return false; - return isOpenCLSpelling(*A); + if (!A) return false; + return isOpenCLSpelling(*A); } }]; } `````````` </details> https://github.com/llvm/llvm-project/pull/143546 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits