diff options
Diffstat (limited to 'test/CodeGenCXX/attr-cleanup.cpp')
-rw-r--r-- | test/CodeGenCXX/attr-cleanup.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/CodeGenCXX/attr-cleanup.cpp b/test/CodeGenCXX/attr-cleanup.cpp new file mode 100644 index 0000000..ff15b03 --- /dev/null +++ b/test/CodeGenCXX/attr-cleanup.cpp @@ -0,0 +1,11 @@ +// RUN: %clang_cc1 -emit-llvm -o - %s | FileCheck %s + +namespace N { + void free(void *i) {} +} + +int main(void) { + // CHECK: call void @_ZN1N4freeEPv + void *fp __attribute__((cleanup(N::free))); + return 0; +} |