================
@@ -3669,6 +3669,7 @@ class Sema final : public SemaBase {
   /// cause problems if the variable is mutable, its initialization is
   /// effectful, or its address is taken.
   bool GloballyUniqueObjectMightBeAccidentallyDuplicated(const VarDecl *Dcl);
+  void DiagnoseDangerousUniqueObjectDuplication(const VarDecl *Dcl);
----------------
DKLoehr wrote:

I think it's meaningful because it's possible for objects to be duplicated 
"harmlessly", in which case we don't warn because the only problem is a little 
extra memory usage. This is the case for constants whose initializers don't 
have side effects.

https://github.com/llvm/llvm-project/pull/125902
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to