diff --git a/clang/lib/CodeGen/CGStmtOpenMP.cpp b/clang/lib/CodeGen/CGStmtOpenMP.cpp index 7721feccb46ee..4910ff6865e43 100644 --- a/clang/lib/CodeGen/CGStmtOpenMP.cpp +++ b/clang/lib/CodeGen/CGStmtOpenMP.cpp @@ -1820,6 +1820,11 @@ class OMPTransformDirectiveScopeRAII { CodeGenFunction::CGCapturedStmtInfo *CGSI = nullptr; CodeGenFunction::CGCapturedStmtRAII *CapInfoRAII = nullptr; + OMPTransformDirectiveScopeRAII(const OMPTransformDirectiveScopeRAII &) = + delete; + OMPTransformDirectiveScopeRAII & + operator=(const OMPTransformDirectiveScopeRAII &) = delete; + public: OMPTransformDirectiveScopeRAII(CodeGenFunction &CGF, const Stmt *S) { if (const auto *Dir = dyn_cast(S)) {