Author: Balázs Kéri Date: 2022-08-25T10:11:40+02:00 New Revision: ab9ee471dfda27b3cfb4a350e406576512ce9053
URL: https://github.com/llvm/llvm-project/commit/ab9ee471dfda27b3cfb4a350e406576512ce9053 DIFF: https://github.com/llvm/llvm-project/commit/ab9ee471dfda27b3cfb4a350e406576512ce9053.diff LOG: [clang-tidy] Add test to cert-dcl58-cpp (NFC). Add a test to cert-dcl58-cpp.cpp to verify that crash in github issue #56902 does not happen. Reviewed By: njames93 Differential Revision: https://reviews.llvm.org/D131686 Added: Modified: clang-tools-extra/test/clang-tidy/checkers/cert/dcl58-cpp.cpp Removed: ################################################################################ diff --git a/clang-tools-extra/test/clang-tidy/checkers/cert/dcl58-cpp.cpp b/clang-tools-extra/test/clang-tidy/checkers/cert/dcl58-cpp.cpp index 79beae12792ff..01964e7dc6c76 100644 --- a/clang-tools-extra/test/clang-tidy/checkers/cert/dcl58-cpp.cpp +++ b/clang-tools-extra/test/clang-tidy/checkers/cert/dcl58-cpp.cpp @@ -268,3 +268,16 @@ struct numeric_limits<::ranges::detail::LongT> { inline constexpr bool numeric_limits<::ranges::detail::LongT>::is_signed; inline constexpr bool numeric_limits<::ranges::detail::LongT>::is_integer; } // namespace std + +namespace no_crash { +struct A +{ + friend struct B; +}; + +struct B; + +template<typename> struct T {}; + +T<B> b; +} _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits