[clang] [NFC][Clang] Fix Static Code Analysis Concerns with copy without assign (PR #75091)
via cfe-commits
cfe-commits at lists.llvm.org
Mon Dec 11 12:00:14 PST 2023
https://github.com/smanna12 created https://github.com/llvm/llvm-project/pull/75091
This patch adds missing assignment operator to the class which has user-defined copy constructor.
>From 8772661bda9c93b8bcfeb67f236468c85d1d0253 Mon Sep 17 00:00:00 2001
From: "Manna, Soumi" <soumi.manna at intel.com>
Date: Mon, 11 Dec 2023 11:58:06 -0800
Subject: [PATCH] [NFC][Clang] Fix Static Code Analysis Concerns with copy
without assign
This patch adds missing assignment operator to the class which has user-defined copy constructor.
---
clang/utils/TableGen/SveEmitter.cpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/clang/utils/TableGen/SveEmitter.cpp b/clang/utils/TableGen/SveEmitter.cpp
index b8a1fb4bab0f49..e7bc63f0af903c 100644
--- a/clang/utils/TableGen/SveEmitter.cpp
+++ b/clang/utils/TableGen/SveEmitter.cpp
@@ -90,6 +90,8 @@ class SVEType {
NumVectors = NumV;
}
+ SVEType &operator=(const SVEType &) = delete;
+
bool isPointer() const { return Pointer; }
bool isVoidPointer() const { return Pointer && Void; }
bool isSigned() const { return Signed; }
More information about the cfe-commits
mailing list