[llvm] [OpenMP] Remove unused isStrictSubset template (NFC) (PR #202987)
Aditya Medhane via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 10 07:08:17 PDT 2026
https://github.com/flash1729 created https://github.com/llvm/llvm-project/pull/202987
The `isStrictSubset` `ArrayRef<T>` template has no callers, so it never instantiates and trips `-Wunused-template`. The `VariantMatchInfo` overload does the work that's actually used, and `isSubset` stays untouched. Removing the dead template.
NFC.
Part of #202945.
>From c64902e11a6bd878451b0e61b578c610f3e915be Mon Sep 17 00:00:00 2001
From: flash1729 <sherlockedaditya at gmail.com>
Date: Wed, 10 Jun 2026 19:34:28 +0530
Subject: [PATCH] [OpenMP] Remove unused isStrictSubset template (NFC)
The `isStrictSubset` `ArrayRef<T>` template has no callers, so it never
instantiates and trips `-Wunused-template`. The `VariantMatchInfo` overload
does the work that's actually used, and `isSubset` stays untouched. Removing
the dead template.
NFC.
Part of #202945.
---
llvm/lib/Frontend/OpenMP/OMPContext.cpp | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/llvm/lib/Frontend/OpenMP/OMPContext.cpp b/llvm/lib/Frontend/OpenMP/OMPContext.cpp
index 6ced5c104c8ef..7443c4c338ada 100644
--- a/llvm/lib/Frontend/OpenMP/OMPContext.cpp
+++ b/llvm/lib/Frontend/OpenMP/OMPContext.cpp
@@ -162,15 +162,6 @@ template <typename T> static bool isSubset(ArrayRef<T> C0, ArrayRef<T> C1) {
return true;
}
-/// Return true if \p C0 is a strict subset of \p C1. Note that both arrays are
-/// expected to be sorted.
-template <typename T>
-static bool isStrictSubset(ArrayRef<T> C0, ArrayRef<T> C1) {
- if (C0.size() >= C1.size())
- return false;
- return isSubset<T>(C0, C1);
-}
-
static bool isStrictSubset(const VariantMatchInfo &VMI0,
const VariantMatchInfo &VMI1) {
// If all required traits are a strict subset and the ordered vectors storing
More information about the llvm-commits
mailing list