[clang] [clang-tools-extra] [clang-tidy] EndSourceFile() for preprocessor before diagnostic client (PR #145784)

2025-07-03 Thread Dave Bartolomeo via cfe-commits
https://github.com/dbartol updated https://github.com/llvm/llvm-project/pull/145784 >From 0be65986e1e2adf973a032936afa9cf48841055b Mon Sep 17 00:00:00 2001 From: Dave Bartolomeo Date: Wed, 25 Jun 2025 17:45:50 -0400 Subject: [PATCH 1/4] EndSourceFile() for preprocessor before diagnostic client

[clang] [clang-tools-extra] [clang-tidy] EndSourceFile() for preprocessor before diagnostic client (PR #145784)

2025-07-03 Thread Dave Bartolomeo via cfe-commits
@@ -1243,13 +1243,15 @@ llvm::Error FrontendAction::Execute() { void FrontendAction::EndSourceFile() { CompilerInstance &CI = getCompilerInstance(); - // Inform the diagnostic client we are done with this source file. - CI.getDiagnosticClient().EndSourceFile(); - // Inf

[clang] [clang-tools-extra] [clang-tidy] EndSourceFile() for preprocessor before diagnostic client (PR #145784)

2025-07-02 Thread Dave Bartolomeo via cfe-commits
https://github.com/dbartol updated https://github.com/llvm/llvm-project/pull/145784 >From 0be65986e1e2adf973a032936afa9cf48841055b Mon Sep 17 00:00:00 2001 From: Dave Bartolomeo Date: Wed, 25 Jun 2025 17:45:50 -0400 Subject: [PATCH 1/3] EndSourceFile() for preprocessor before diagnostic client

[clang] [clang-tools-extra] [clang-tidy] EndSourceFile() for preprocessor before diagnostic client (PR #145784)

2025-06-26 Thread Dave Bartolomeo via cfe-commits
@@ -360,6 +360,12 @@ getFixIt(const tooling::Diagnostic &Diagnostic, bool AnyFix) { void ClangTidyDiagnosticConsumer::HandleDiagnostic( DiagnosticsEngine::Level DiagLevel, const Diagnostic &Info) { + assert(InSourceFile || + Info.getLocation() + .isIn

[clang] [clang-tools-extra] [clang-tidy] EndSourceFile() for preprocessor before diagnostic client (PR #145784)

2025-06-26 Thread Dave Bartolomeo via cfe-commits
https://github.com/dbartol updated https://github.com/llvm/llvm-project/pull/145784 >From 0be65986e1e2adf973a032936afa9cf48841055b Mon Sep 17 00:00:00 2001 From: Dave Bartolomeo Date: Wed, 25 Jun 2025 17:45:50 -0400 Subject: [PATCH 1/2] EndSourceFile() for preprocessor before diagnostic client

[clang] [clang-tools-extra] [clang-tidy] EndSourceFile() for preprocessor before diagnostic client (PR #145784)

2025-06-26 Thread Dave Bartolomeo via cfe-commits
https://github.com/dbartol edited https://github.com/llvm/llvm-project/pull/145784 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] EndSourceFile() for preprocessor before diagnostic client (PR #145784)

2025-06-25 Thread Dave Bartolomeo via cfe-commits
https://github.com/dbartol updated https://github.com/llvm/llvm-project/pull/145784 >From 0be65986e1e2adf973a032936afa9cf48841055b Mon Sep 17 00:00:00 2001 From: Dave Bartolomeo Date: Wed, 25 Jun 2025 17:45:50 -0400 Subject: [PATCH] EndSourceFile() for preprocessor before diagnostic client The

[clang] Fix `pragma-comment.c` test failing on false match (PR #145455)

2025-06-24 Thread Dave Bartolomeo via cfe-commits
https://github.com/dbartol created https://github.com/llvm/llvm-project/pull/145455 Sometimes the forbidden text `foo` or `bar` could appear in the Clang version string metadata. Treating the version string as a `CHECK-LABEL:` prevents this. Fixes #145453 >From 252441c2a828d9bda1d74cec2f1f37

[clang] Fix `pragma-comment.c` test failing on false match (PR #145455)

2025-06-24 Thread Dave Bartolomeo via cfe-commits
@@ -32,3 +32,6 @@ // ELF: ![[space]] = !{!"with space"} // ELF-NOT: bar // ELF-NOT: foo +// This following match prevents the clang version metadata from matching the forbidden 'foo' and 'bar' tokens. +// This can happen if the clang version string contains a Git repo URL that

r296843 - Fix msc-version.c test to handle _MSC_VER=1910

2017-03-02 Thread Dave Bartolomeo via cfe-commits
Author: dbartol Date: Thu Mar 2 18:08:55 2017 New Revision: 296843 URL: http://llvm.org/viewvc/llvm-project?rev=296843&view=rev Log: Fix msc-version.c test to handle _MSC_VER=1910 Previously, VC++ has always set _MSC_VER to a four-digit value with the two least significant digits set to zero. V

Re: [PATCH] D22426: Fix automatic detection of ARM MSVC toolset in clang.exe

2016-07-26 Thread Dave Bartolomeo via cfe-commits
DaveBartolomeo updated this revision to Diff 65633. DaveBartolomeo added a comment. Herald added a subscriber: samparker. Updated the selection algorithm based on review feedback. Now, if clang.exe itself is x64-hosted, we'll look for the x64-hosted MSVC toolset if it exists. If clang.exe is not

Re: [PATCH] D22426: Fix automatic detection of ARM MSVC toolset in clang.exe

2016-07-20 Thread Dave Bartolomeo via cfe-commits
DaveBartolomeo added a comment. Just to make sure I'm clear on the consensus, the new plan is: If clang.exe is x64-hosted and an x64-hosted MSVC toolchain is available, use the x64-hosted MSVC toolchain. Otherwise, use the x86-hosted MSVC toolchain. Right? https://reviews.llvm.org/D22426 _

Re: [PATCH] D22426: Fix automatic detection of ARM MSVC toolset in clang.exe

2016-07-15 Thread Dave Bartolomeo via cfe-commits
DaveBartolomeo added a comment. In https://reviews.llvm.org/D22426#486100, @compnerd wrote: > I imagine that at this point, most usage is still based around the x86 > toolchain rather than x64 (I didnt even notice the x64 tools until recently). > That is, any reason that we shouldnt be using x

[PATCH] D22426: Fix automatic detection of ARM MSVC toolset in clang.exe

2016-07-15 Thread Dave Bartolomeo via cfe-commits
DaveBartolomeo created this revision. DaveBartolomeo added reviewers: rnk, majnemer, cfe-commits. Herald added subscribers: rengolin, aemerson. Clang was failing to find the ARM version of the MSVC link.exe, even though it could correctly find link.exe for x86 and x64. Clang looks in the %VCINST

Re: [PATCH] D22273: Treat enumerator_too_large as an extension in MS ABI mode

2016-07-15 Thread Dave Bartolomeo via cfe-commits
DaveBartolomeo abandoned this revision. DaveBartolomeo added a comment. I'll attempt to fix the underlying issue https://llvm.org/bugs/show_bug.cgi?id=27098 instead. https://reviews.llvm.org/D22273 ___ cfe-commits mailing list cfe-commits@lists.llv

[PATCH] D22293: Fix MSVC mangling of consecutive pack template arguments

2016-07-12 Thread Dave Bartolomeo via cfe-commits
DaveBartolomeo created this revision. DaveBartolomeo added reviewers: rnk, majnemer, cfe-commits. When mangling a template specialization where two consecutive template arguments are both packs, MSVC inserts the separator "$$Z" between the two arguments to disambiguate between the case of { { in

[PATCH] D22275: Support -fno-delayed-template-parsing in clang-cl.exe

2016-07-12 Thread Dave Bartolomeo via cfe-commits
DaveBartolomeo created this revision. DaveBartolomeo added reviewers: rnk, majnemer, cfe-commits. This change adds support for the -fno-delayed-template-parsing option in clang-cl.exe. This allows developers using clang-cl.exe to opt out of emulation of MSVC's non-conformant template instantiati

[PATCH] D22273: Treat enumerator_too_large as an extension in MS ABI mode

2016-07-12 Thread Dave Bartolomeo via cfe-commits
DaveBartolomeo created this revision. DaveBartolomeo added reviewers: rnk, cfe-commits. When compiling as C targeting the MS ABI, but with -fno-ms-compatibility, an enumerator initializer that is not representable as an int is treated as an error. This is correct according to the C standard, but

Re: [PATCH] D20492: Clang support for __is_assignable intrinsic

2016-05-20 Thread Dave Bartolomeo via cfe-commits
DaveBartolomeo updated this revision to Diff 58014. DaveBartolomeo added a comment. Removed unnecessary braces. Moved BTT_IsAssignable case to a more clear location. http://reviews.llvm.org/D20492 Files: docs/LanguageExtensions.rst include/clang/Basic/TokenKinds.def include/clang/Basic/Ty

[PATCH] D20492: Clang support for __is_assignable intrinsic

2016-05-20 Thread Dave Bartolomeo via cfe-commits
DaveBartolomeo created this revision. DaveBartolomeo added a reviewer: rnk. DaveBartolomeo added a subscriber: cfe-commits. MSVC now supports the __is_assignable type trait intrinsic, to enable easier and more efficient implementation of the Standard Library's is_assignable trait. As of Visual S