[clang] [ByteCode] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123445)

2025-01-17 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123445 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123444)

2025-01-17 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123444 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [AST] Avoid repeated hash lookups (NFC) (PR #123285)

2025-01-17 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/123285 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123284)

2025-01-17 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/123284 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123283)

2025-01-17 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/123283 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Avoid repeated hash lookups (NFC) (PR #123285)

2025-01-16 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123285 None >From 1baa9c7445a6e65a6c9086994e728db463fe6a5f Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Thu, 16 Jan 2025 09:56:31 -0800 Subject: [PATCH] [AST] Avoid repeated hash lookups (NFC) --- clang/l

[clang] [Sema] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123284)

2025-01-16 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123284 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123283)

2025-01-16 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123283 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [Sema] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123158)

2025-01-16 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/123158 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CodeGen] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123157)

2025-01-16 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/123157 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123156)

2025-01-16 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/123156 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123158)

2025-01-15 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123158 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [CodeGen] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123157)

2025-01-15 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123157 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123156)

2025-01-15 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123156 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] 1c5f874 - [Driver] Fix a warning

2025-01-15 Thread Kazu Hirata via cfe-commits
Author: Kazu Hirata Date: 2025-01-15T08:52:53-08:00 New Revision: 1c5f87486aabd0eed2b41d32fc499700e4471f11 URL: https://github.com/llvm/llvm-project/commit/1c5f87486aabd0eed2b41d32fc499700e4471f11 DIFF: https://github.com/llvm/llvm-project/commit/1c5f87486aabd0eed2b41d32fc499700e4471f11.diff L

[clang] [Sema] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123014)

2025-01-15 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/123014 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CodeGen] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123013)

2025-01-15 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/123013 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123012)

2025-01-15 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/123012 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123014)

2025-01-14 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123014 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [CodeGen] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123013)

2025-01-14 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123013 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #123012)

2025-01-14 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/123012 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [StaticAnalyzer] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122856)

2025-01-14 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata updated https://github.com/llvm/llvm-project/pull/122856 >From 492cea234d3d7b2a017d1e926272e95bf5fbfefc Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Mon, 13 Jan 2025 12:16:18 -0800 Subject: [PATCH 1/2] [StaticAnalyzer] Migrate away from PointerUnion::dyn_ca

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122854)

2025-01-14 Thread Kazu Hirata via cfe-commits
kazutakahirata wrote: > You are still using dyn_cast_if_present :) Sorry about that. Fixed. https://github.com/llvm/llvm-project/pull/122854 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122854)

2025-01-14 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata updated https://github.com/llvm/llvm-project/pull/122854 >From 4b3e0285a506072869452e2d422f3aff494517db Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Mon, 13 Jan 2025 12:04:16 -0800 Subject: [PATCH 1/2] [AST] Migrate away from PointerUnion::dyn_cast (NFC) N

[clang] [StaticAnalyzer] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122856)

2025-01-14 Thread Kazu Hirata via cfe-commits
kazutakahirata wrote: > This one also uses dyn_cast_if_present. Sorry about that. Fixed. https://github.com/llvm/llvm-project/pull/122856 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

[clang] [AST] Avoid repeated map lookups (NFC) (PR #122858)

2025-01-13 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/122858 None >From 227e7f718acbef18a4b5e93cc6ea8cc0b2249062 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Mon, 13 Jan 2025 21:08:39 -0800 Subject: [PATCH] [AST] Avoid repeated map lookups (NFC) --- clang/li

[clang] [StaticAnalyzer] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122856)

2025-01-13 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/122856 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [Sema] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122855)

2025-01-13 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/122855 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122854)

2025-01-13 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/122854 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [CodeGen] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122778)

2025-01-13 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/122778 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CodeGen] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122778)

2025-01-13 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/122778 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [Analysis] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122652)

2025-01-13 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/122652 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122651)

2025-01-13 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/122651 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122651)

2025-01-12 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/122651 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [CodeGen] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122653)

2025-01-12 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/122653 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [Analysis] Migrate away from PointerUnion::dyn_cast (NFC) (PR #122652)

2025-01-12 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/122652 Note that PointerUnion::dyn_cast has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast Literal migration

[clang] [Driver] Avoid repeated map lookups (NFC) (PR #122625)

2025-01-11 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/122625 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Avoid repeated map lookups (NFC) (PR #122625)

2025-01-11 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/122625 None >From b9a6a99e421170fbc1fb8c6641a83d21dfa0076c Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Sat, 11 Jan 2025 17:53:36 -0800 Subject: [PATCH] [Driver] Avoid repeated map lookups (NFC) --- clang

[clang] [Sema] Avoid repeated hash lookups (NFC) (PR #122588)

2025-01-11 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/122588 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Avoid repeated hash lookups (NFC) (PR #122588)

2025-01-11 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/122588 None >From 7b2b5230116779c07db74056eba6618fdea7f910 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Sat, 11 Jan 2025 01:11:22 -0800 Subject: [PATCH] [Sema] Avoid repeated hash lookups (NFC) --- clang/

[clang] a3e62d8 - [AST] Fix a warning

2025-01-11 Thread Kazu Hirata via cfe-commits
Author: Kazu Hirata Date: 2025-01-11T00:11:42-08:00 New Revision: a3e62d849f07d1e55e6d15465f4f3842ff4b3717 URL: https://github.com/llvm/llvm-project/commit/a3e62d849f07d1e55e6d15465f4f3842ff4b3717 DIFF: https://github.com/llvm/llvm-project/commit/a3e62d849f07d1e55e6d15465f4f3842ff4b3717.diff L

[clang-tools-extra] [clang-doc] Migrate away from PointerUnion::{is,get} (NFC) (PR #120872)

2024-12-22 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/120872 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] Migrate away from PointerUnion::{is,get} (NFC) (PR #120872)

2024-12-21 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/120872 Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast >From 74f40fd73

[clang] [Serialization] Migrate away from PointerUnion::get (NFC) (PR #120844)

2024-12-21 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/120844 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Serialization] Migrate away from PointerUnion::get (NFC) (PR #120844)

2024-12-21 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/120844 Note that PointerUnion::get has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast I'm not touching Point

[clang] [Sema] Migrate away from PointerUnion::{is, get} (NFC) (PR #120829)

2024-12-21 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/120829 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Migrate away from PointerUnion::{is, get} (NFC) (PR #120829)

2024-12-21 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/120829 Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast I'm moving the d

[clang] [compiler-rt] [llvm] [TySan] A Type Sanitizer (Runtime Library) (PR #76261)

2024-12-17 Thread Kazu Hirata via cfe-commits
kazutakahirata wrote: > AFAICT this is happening at each place that includes the file, e.g. also if > you build AddressSanitizer. Not sure what the best way forward here is as > this is not related to TypeSanitizer, but seems to impact all sanitizers? I just posted https://github.com/llvm/llvm

[clang] [compiler-rt] [llvm] [TySan] A Type Sanitizer (Runtime Library) (PR #76261)

2024-12-17 Thread Kazu Hirata via cfe-commits
kazutakahirata wrote: @fhahn I'm getting: ``` compiler-rt/lib/tysan/../sanitizer_common/sanitizer_platform_limits_posix.h:604:3: error: anonymous structs are a GNU extension [-Werror,-Wgnu-anonymous-struct] struct { ^ 1 error generated. ``` while compiling `tyscan.cpp`. Is there any way y

[clang] [AST] Migrate away from PointerUnion::get (NFC) (PR #119949)

2024-12-14 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/119949 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Migrate away from PointerUnion::get (NFC) (PR #119949)

2024-12-13 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/119949 Note that PointerUnion::get has been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast >From 07399e5edcbd8ac

[clang] [clang] Migrate away from PointerUnion::{is, get} (NFC) (PR #119724)

2024-12-12 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/119724 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Migrate away from PointerUnion::{is, get} (NFC) (PR #119724)

2024-12-12 Thread Kazu Hirata via cfe-commits
kazutakahirata wrote: @nikic Please take a look at the revised patch. Thanks! https://github.com/llvm/llvm-project/pull/119724 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Migrate away from PointerUnion::{is, get} (NFC) (PR #119724)

2024-12-12 Thread Kazu Hirata via cfe-commits
@@ -486,10 +486,10 @@ enum class TemplateSubstitutionKind : char { const Decl *D = I->first; llvm::PointerUnion &Stored = newScope->LocalDecls[D]; -if (I->second.is()) { - Stored = I->second.get(); +if (isa(I->second)) { +

[clang] [clang] Migrate away from PointerUnion::{is, get} (NFC) (PR #119724)

2024-12-12 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata updated https://github.com/llvm/llvm-project/pull/119724 >From 6fc978bce4321bb24ade49f2f6fde0c7ccd0002b Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Thu, 12 Dec 2024 09:06:22 -0800 Subject: [PATCH 1/2] [clang] Migrate away from PointerUnion::{is,get} (NFC)

[clang] [clang] Migrate away from PointerUnion::{is, get} (NFC) (PR #119724)

2024-12-12 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/119724 Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast I'm not touching

[clang] [AST] Migrate away from PointerUnion::{is, get} (NFC) (PR #119673)

2024-12-12 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/119673 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Migrate away from PointerUnion::{is, get} (NFC) (PR #119673)

2024-12-12 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/119673 Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast I'm not touching

[clang] [clang] Migrate away from PointerUnion::{is, get} (NFC) (PR #119654)

2024-12-11 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/119654 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Migrate away from PointerUnion::{is, get} (NFC) (PR #119654)

2024-12-11 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/119654 Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast I'm not touching

[clang] [AST] Migrate away from PointerUnion::{is, get} (NFC) (PR #119523)

2024-12-11 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/119523 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Migrate away from PointerUnion::{is, get} (NFC) (PR #119523)

2024-12-11 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata edited https://github.com/llvm/llvm-project/pull/119523 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Serialization] Migrate away from PointerUnion::{is,get} (NFC) (PR #118948)

2024-12-09 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/118948 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Serialization] Migrate away from PointerUnion::{is,get} (NFC) (PR #118948)

2024-12-06 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/118948 Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast I'm not touching

[clang] [CodeGen] Migrate away from PointerUnion::{is, get} (NFC) (PR #118600)

2024-12-06 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/118600 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Include clang/Basic/DiagnosticComment.h instead of clang/AST/CommentDiagnostic.h (PR #117499)

2024-12-06 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/117499 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Include clang/Basic/DiagnosticComment.h instead of clang/AST/CommentDiagnostic.h (PR #117499)

2024-12-06 Thread Kazu Hirata via cfe-commits
kazutakahirata wrote: I'm going to go conservative for now by including `clang/Basic/DiagnosticComment.h` instead of `clang/AST/CommentDiagnostic.h`. We can revisit this and remove `clang/AST/CommentDiagnostic.h` and update `module.modulemap`. https://github.com/llvm/llvm-project/pull/117499

[clang] [AST] Include clang/Basic/DiagnosticComment.h instead of clang/AST/CommentDiagnostic.h (PR #117499)

2024-12-06 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata edited https://github.com/llvm/llvm-project/pull/117499 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Include clang/Basic/DiagnosticComment.h instead of clang/AST/CommentDiagnostic.h (PR #117499)

2024-12-06 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata edited https://github.com/llvm/llvm-project/pull/117499 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Remove clang/AST/CommentDiagnostic.h (PR #117499)

2024-12-05 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata updated https://github.com/llvm/llvm-project/pull/117499 >From e9427756de508dc386a10ee9ee19cc4733a40465 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Sun, 24 Nov 2024 09:14:54 -0800 Subject: [PATCH 1/2] [AST] Remove clang/AST/CommentDiagnostic.h Since: c

[clang] [CodeGen] Migrate away from PointerUnion::{is, get} (NFC) (PR #118600)

2024-12-05 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata updated https://github.com/llvm/llvm-project/pull/118600 >From 651f7ab264c5fd2b1fdd740b3d84e2aef4681b4b Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Tue, 3 Dec 2024 13:59:08 -0800 Subject: [PATCH 1/2] [CodeGen] Migrate away from PointerUnion::{is,get} (NFC)

[clang] [CodeGen] Migrate away from PointerUnion::{is, get} (NFC) (PR #118600)

2024-12-05 Thread Kazu Hirata via cfe-commits
@@ -37,8 +37,8 @@ void ConstantInitFuture::abandon() { void ConstantInitFuture::installInGlobal(llvm::GlobalVariable *GV) { assert(Data && "installing null future"); - if (Data.is()) { -GV->setInitializer(Data.get()); + if (auto *C = dyn_cast(Data)) { +GV->setIniti

[clang] 32b821c - [AST] Fix a warning

2024-12-04 Thread Kazu Hirata via cfe-commits
Author: Kazu Hirata Date: 2024-12-04T16:03:14-08:00 New Revision: 32b821cab3064ae9a77a0f1d9916a286c7543735 URL: https://github.com/llvm/llvm-project/commit/32b821cab3064ae9a77a0f1d9916a286c7543735 DIFF: https://github.com/llvm/llvm-project/commit/32b821cab3064ae9a77a0f1d9916a286c7543735.diff L

[clang] [CodeGen] Migrate away from PointerUnion::{is, get} (NFC) (PR #118600)

2024-12-03 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/118600 Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast I'm not touching

[clang-tools-extra] 94d6b1c - [clangd] Fix warnings

2024-12-03 Thread Kazu Hirata via cfe-commits
Author: Kazu Hirata Date: 2024-12-03T23:17:57-08:00 New Revision: 94d6b1cce5bb9449971a027e352385e72b059a3a URL: https://github.com/llvm/llvm-project/commit/94d6b1cce5bb9449971a027e352385e72b059a3a DIFF: https://github.com/llvm/llvm-project/commit/94d6b1cce5bb9449971a027e352385e72b059a3a.diff L

[clang] [StaticAnalyzer] Migrate away from PointerUnion::{is,get} (NFC) (PR #118421)

2024-12-03 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/118421 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [StaticAnalyzer] Migrate away from PointerUnion::{is,get} (NFC) (PR #118421)

2024-12-03 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata updated https://github.com/llvm/llvm-project/pull/118421 >From 45da9c47e9cfb6c24a6a3e0bba89fa25a4bf2a2a Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Wed, 27 Nov 2024 09:15:12 -0800 Subject: [PATCH 1/3] [StaticAnalyzer] Migrate away from PointerUnion::{is,ge

[clang] [StaticAnalyzer] Migrate away from PointerUnion::{is,get} (NFC) (PR #118421)

2024-12-03 Thread Kazu Hirata via cfe-commits
@@ -205,10 +205,10 @@ const NamedDecl *nonloc::PointerToMember::getDecl() const { return nullptr; const NamedDecl *ND = nullptr; - if (PTMD.is()) -ND = PTMD.get(); + if (isa(PTMD)) kazutakahirata wrote: Done. https://github.com/llvm/llvm-project

[clang] [StaticAnalyzer] Migrate away from PointerUnion::{is,get} (NFC) (PR #118421)

2024-12-03 Thread Kazu Hirata via cfe-commits
@@ -222,23 +222,23 @@ void ExplodedNode::NodeGroup::addNode(ExplodedNode *N, ExplodedGraph &G) { GroupStorage &Storage = reinterpret_cast(P); if (Storage.isNull()) { Storage = N; -assert(Storage.is()); +assert(isa(Storage)); return; } ExplodedNodeV

[clang] [StaticAnalyzer] Migrate away from PointerUnion::{is,get} (NFC) (PR #118421)

2024-12-03 Thread Kazu Hirata via cfe-commits
@@ -196,13 +196,13 @@ const PointerToMemberData *BasicValueFactory::accumCXXBase( const NamedDecl *ND = nullptr; llvm::ImmutableList BaseSpecList; - if (PTMDT.isNull() || PTMDT.is()) { -if (PTMDT.is()) - ND = PTMDT.get(); + if (PTMDT.isNull() || isa(PTMDT)) { +

[clang] [StaticAnalyzer] Migrate away from PointerUnion::{is,get} (NFC) (PR #118421)

2024-12-03 Thread Kazu Hirata via cfe-commits
@@ -211,8 +211,8 @@ class MallocSizeofChecker : public Checker { continue; const TypeSourceInfo *TSI = nullptr; -if (CallRec.CastedExprParent.is()) { - TSI = CallRec.CastedExprParent.get() +if (isa(CallRec.CastedExprParent)) { --

[clang] [StaticAnalyzer] Migrate away from PointerUnion::{is,get} (NFC) (PR #118421)

2024-12-03 Thread Kazu Hirata via cfe-commits
@@ -196,13 +196,13 @@ const PointerToMemberData *BasicValueFactory::accumCXXBase( const NamedDecl *ND = nullptr; llvm::ImmutableList BaseSpecList; - if (PTMDT.isNull() || PTMDT.is()) { -if (PTMDT.is()) - ND = PTMDT.get(); + if (PTMDT.isNull() || isa(PTMDT)) { +

[clang] [StaticAnalyzer] Migrate away from PointerUnion::{is,get} (NFC) (PR #118421)

2024-12-03 Thread Kazu Hirata via cfe-commits
@@ -1068,10 +1068,10 @@ const VarRegion *MemRegionManager::getVarRegion(const VarDecl *D, llvm::PointerUnion V = getStackOrCaptureRegionForDeclContext(LC, DC, D); -if (V.is()) - return V.get(); +if (isa(V)) kazutakahirata wrote: Switch

[clang] [StaticAnalyzer] Migrate away from PointerUnion::{is,get} (NFC) (PR #118421)

2024-12-03 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata updated https://github.com/llvm/llvm-project/pull/118421 >From 45da9c47e9cfb6c24a6a3e0bba89fa25a4bf2a2a Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Wed, 27 Nov 2024 09:15:12 -0800 Subject: [PATCH 1/2] [StaticAnalyzer] Migrate away from PointerUnion::{is,ge

[clang] [StaticAnalyzer] Migrate away from PointerUnion::{is,get} (NFC) (PR #118421)

2024-12-02 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/118421 Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast I'm not touching

[clang] [Sema] Migrate away from PointerUnion::{is, get} (NFC) (PR #117498)

2024-11-27 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/117498 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Sema] Migrate away from PointerUnion::{is, get} (NFC) (PR #117498)

2024-11-27 Thread Kazu Hirata via cfe-commits
kazutakahirata wrote: @nikic Friendly ping. Thanks! https://github.com/llvm/llvm-project/pull/117498 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 2a5e3a6 - [AST] Fix a warning

2024-11-24 Thread Kazu Hirata via cfe-commits
Author: Kazu Hirata Date: 2024-11-24T16:37:23-08:00 New Revision: 2a5e3a67a0248db4a6981e343f0033a32ad4a577 URL: https://github.com/llvm/llvm-project/commit/2a5e3a67a0248db4a6981e343f0033a32ad4a577 DIFF: https://github.com/llvm/llvm-project/commit/2a5e3a67a0248db4a6981e343f0033a32ad4a577.diff L

[clang] [AST] Remove clang/AST/CommentDiagnostic.h (PR #117499)

2024-11-24 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/117499 Since: commit d076608d58d1ec55016eb747a995511e3a3f72aa Author: Richard Trieu Date: Sat Dec 8 05:05:03 2018 + clang/AST/CommentDiagnostic.h has been forwarding to clang/Basic/DiagnosticParse.

[clang] [Sema] Migrate away from PointerUnion::{is, get} (NFC) (PR #117498)

2024-11-24 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/117498 Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast I'm not touching

[clang] [AST] Migrate away from PointerUnion::{is, get} (NFC) (PR #117469)

2024-11-24 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/117469 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Migrate away from PointerUnion::{is, get} (NFC) (PR #117469)

2024-11-23 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/117469 Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with //isa, cast and the llvm::dyn_cast I'm not touching

[clang] 14b9ca3 - [Sema] Fix a warning

2024-11-23 Thread Kazu Hirata via cfe-commits
Author: Kazu Hirata Date: 2024-11-23T10:29:11-08:00 New Revision: 14b9ca3f38494bbd03709188b6e73c06ab84cd15 URL: https://github.com/llvm/llvm-project/commit/14b9ca3f38494bbd03709188b6e73c06ab84cd15 DIFF: https://github.com/llvm/llvm-project/commit/14b9ca3f38494bbd03709188b6e73c06ab84cd15.diff L

[clang] f881a38 - [CodeGen] Fix a warning

2024-11-21 Thread Kazu Hirata via cfe-commits
Author: Kazu Hirata Date: 2024-11-21T10:27:05-08:00 New Revision: f881a3815a6b58afa64277eee0bb6b91a4dde103 URL: https://github.com/llvm/llvm-project/commit/f881a3815a6b58afa64277eee0bb6b91a4dde103 DIFF: https://github.com/llvm/llvm-project/commit/f881a3815a6b58afa64277eee0bb6b91a4dde103.diff L

[clang] [Parse] Remove ParseDiagnostic.h (PR #116496)

2024-11-18 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/116496 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Remove unused includes (NFC) (PR #116549)

2024-11-17 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/116549 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Remove unused includes (NFC) (PR #116549)

2024-11-17 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata edited https://github.com/llvm/llvm-project/pull/116549 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AST] Avoid repeated hash lookups (NFC) (PR #116549)

2024-11-17 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/116549 Identified with misc-include-cleaner. >From a11ea3a089d42b2e11d5a32cc490665f7fd4efbd Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Sun, 17 Nov 2024 09:04:05 -0800 Subject: [PATCH] [AST] Avoid repeate

[clang] [Lex] Remove unused includes (NFC) (PR #116460)

2024-11-16 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata closed https://github.com/llvm/llvm-project/pull/116460 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Parse] Remove ParseDiagnostic.h (PR #116496)

2024-11-16 Thread Kazu Hirata via cfe-commits
kazutakahirata wrote: > Can you explain what is the perceived benefit of this change? Thanks Sure. - We'll have less code. - We'll have fewer "false positives" from clangd's "unused include" warnings. The .cpp files are not using anything declared in `ParseDiagnostic.h` because, after all, `

  1   2   3   4   5   6   7   8   9   10   >