diff options
| author | Anders Carlsson <andersca@mac.com> | 2009-06-01 00:05:16 +0000 |
|---|---|---|
| committer | Anders Carlsson <andersca@mac.com> | 2009-06-01 00:05:16 +0000 |
| commit | ca50119a31d335b46dcc9940f6f6fd6cabe8ea33 (patch) | |
| tree | 1d11fc75af29b8aeeae18f916a749d6488d199d5 /clang/test/CodeGenCXX/new.cpp | |
| parent | cba81fc4de83b0ffa430c94b9ad88b8cf7bb1622 (diff) | |
| download | bcm5719-llvm-ca50119a31d335b46dcc9940f6f6fd6cabe8ea33.tar.gz bcm5719-llvm-ca50119a31d335b46dcc9940f6f6fd6cabe8ea33.zip | |
Check for null correctly for new expressions.
llvm-svn: 72678
Diffstat (limited to 'clang/test/CodeGenCXX/new.cpp')
| -rw-r--r-- | clang/test/CodeGenCXX/new.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/test/CodeGenCXX/new.cpp b/clang/test/CodeGenCXX/new.cpp index e3d1ec1df6c..70ad269d24a 100644 --- a/clang/test/CodeGenCXX/new.cpp +++ b/clang/test/CodeGenCXX/new.cpp @@ -45,3 +45,8 @@ void t5() { // RUN: grep "call void @_ZN2T2C1Eii" %t | count 1 T2 *t2 = new T2(10, 10); } + +int *t6() { + // Null check. + return new (0) int(10); +} |

