diff options
| author | Anders Carlsson <andersca@mac.com> | 2009-05-31 20:26:12 +0000 |
|---|---|---|
| committer | Anders Carlsson <andersca@mac.com> | 2009-05-31 20:26:12 +0000 |
| commit | 6f9dabff6daf7cb984f40aa067693c0f3ad15459 (patch) | |
| tree | e830d9419b494f07585128b4b3d62c7aec14d5f2 /clang/test | |
| parent | 1832f52b10f8b3ec0b497ea5b7f7dd2f581b3a3b (diff) | |
| download | bcm5719-llvm-6f9dabff6daf7cb984f40aa067693c0f3ad15459.tar.gz bcm5719-llvm-6f9dabff6daf7cb984f40aa067693c0f3ad15459.zip | |
Make sure to copy back arguments that can be changed by FindAllocationOverload. This fixes placement new. (Sebastian, please review).
llvm-svn: 72673
Diffstat (limited to 'clang/test')
| -rw-r--r-- | clang/test/CodeGenCXX/new.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/clang/test/CodeGenCXX/new.cpp b/clang/test/CodeGenCXX/new.cpp index fddda2b5b5f..d07466db671 100644 --- a/clang/test/CodeGenCXX/new.cpp +++ b/clang/test/CodeGenCXX/new.cpp @@ -3,3 +3,10 @@ void t1() { int* a = new int; } + +// Placement. +void* operator new(unsigned long, void*) throw(); + +void t2(int* a) { + int* b = new (a) int; +} |

