ClockMan added inline comments.
================ Comment at: clang-tools-extra/clang-tidy/llvmlibc/InlineFunctionDeclCheck.cpp:31 + // Consider functions only in header files. + if (!Result.SourceManager->getFilename(SrcBegin).ends_with(".h")) + return; ---------------- Probably better would be to check if this isn't main source Result.SourceManager->isInMainFile(SrcBegin) ================ Comment at: clang-tools-extra/clang-tidy/llvmlibc/InlineFunctionDeclCheck.cpp:35 + auto Loc = FullSourceLoc(SrcBegin, *Result.SourceManager); + if (Loc.getBufferData().starts_with("LIBC_INLINE")) + return; ---------------- Maybe put this LIBC_INLINE into some configuration, so check could be used by someone else also for other macros. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142592/new/ https://reviews.llvm.org/D142592 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits