[compiler-rt] Test fixups for MSVC. (PR #109887)
Charlie Barto via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 25 13:54:12 PDT 2024
================
@@ -2,12 +2,18 @@
// RUN: %clang_cl_asan %LD %Od %s %Fe%t.dll
// RUN: not %run %t %t.dll 2>&1 | FileCheck %s
+#include "../defines.h"
+
struct C {
int x;
~C() {}
};
-int __attribute__((noinline, optnone)) hide(int x) { return x; }
+int ATTRIBUTE_NOINLINE
+#if __clang__ || !defined(_MSC_VER)
----------------
barcharcraz wrote:
I think this is somewhat stylistic. I can switch to defined instead of relying on the substitution of undefined identifiers for 0 though, it's a reasonable style.
https://github.com/llvm/llvm-project/pull/109887
More information about the llvm-commits
mailing list