Files
clang-p2996/compiler-rt/test/asan/TestCases/Windows/stack_array_sanity.cpp
Alvin Wong 3c1aa20c63 [asan][test][win] Port trivial tests to not use clang-cl on MinGW
Use clang driver on MinGW where clang-cl is not usable. MSVC target
still uses clang-cl to minimize changes to existing test runners.

Differential Revision: https://reviews.llvm.org/D147432
2023-04-21 21:25:49 +08:00

13 lines
200 B
C++

// RUN: %clang_cl_asan %Od %s %Fe%t
// RUN: %run %t | FileCheck %s
#include <stdio.h>
int main() {
int subscript = 1;
char buffer[42];
buffer[subscript] = 42;
printf("OK\n");
// CHECK: OK
}