Apparently the analyzer does not detect that assigning the `1` address will never return. --- include/common/debug.h | 4 ++++ 1 file changed, 4 insertions(+)
diff --git a/include/common/debug.h b/include/common/debug.h index d6bc3c208..c38acdf53 100644 --- a/include/common/debug.h +++ b/include/common/debug.h @@ -40,7 +40,11 @@ /* This abort is more efficient than abort() because it does not mangle the * stack and stops at the exact location we need. */ +#ifdef __clang_analyzer__ +#define ABORT_NOW() abort() +#else #define ABORT_NOW() (*(volatile int*)1=0) +#endif /* BUG_ON: complains if <cond> is true when DEBUG_STRICT or DEBUG_STRICT_NOCRASH * are set, does nothing otherwise. With DEBUG_STRICT in addition it immediately -- 2.21.0

