[llvm] [ASan][ADT] Don't scribble with ASan (PR #79066)

via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 23 10:03:19 PST 2024


================
@@ -317,8 +317,10 @@ template <typename ReturnT, typename... ParamTs> class UniqueFunctionBase {
     // Clear the old callback and inline flag to get back to as-if-null.
     RHS.CallbackAndInlineFlag = {};
 
-#ifndef NDEBUG
-    // In debug builds, we also scribble across the rest of the storage.
+#if !defined(NDEBUG) && !defined(LLVM_ADDRESS_SANITIZER_BUILD)
+    // In debug builds without ASan, we also scribble across the rest of the
----------------
AdvenamTacet wrote:

I fixed the text to be more precise. Thx!

https://github.com/llvm/llvm-project/pull/79066


More information about the llvm-commits mailing list