diff options
Diffstat (limited to 'Include/Python.h')
-rw-r--r-- | Include/Python.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/Include/Python.h b/Include/Python.h index cf87a5c..bece208 100644 --- a/Include/Python.h +++ b/Include/Python.h @@ -53,6 +53,15 @@ #include "pyport.h" #include "pymacro.h" +/* A convenient way for code to know if clang's memory sanitizer is enabled. */ +#if defined(__has_feature) +# if __has_feature(memory_sanitizer) +# if !defined(MEMORY_SANITIZER) +# define MEMORY_SANITIZER +# endif +# endif +#endif + /* Debug-mode build with pymalloc implies PYMALLOC_DEBUG. * PYMALLOC_DEBUG is in error if pymalloc is not in use. */ |