diff options
author | Eli Friedman <eli.friedman@gmail.com> | 2009-11-16 05:31:29 +0000 |
---|---|---|
committer | Eli Friedman <eli.friedman@gmail.com> | 2009-11-16 05:31:29 +0000 |
commit | e6ce354795cd7f01b386df1cb928b386f971ddd7 (patch) | |
tree | 195fec539ed5aa5699a02e8611ec0ede23908f40 /clang/test/CodeGenCXX/virtual-operator-call.cpp | |
parent | 011c4c341bd7c3ecded6b113d47058b072747e96 (diff) | |
download | bcm5719-llvm-e6ce354795cd7f01b386df1cb928b386f971ddd7.tar.gz bcm5719-llvm-e6ce354795cd7f01b386df1cb928b386f971ddd7.zip |
Fix a couple of cases where we weren't generating the right kind of call
for a call to a virtual function.
llvm-svn: 88891
Diffstat (limited to 'clang/test/CodeGenCXX/virtual-operator-call.cpp')
-rw-r--r-- | clang/test/CodeGenCXX/virtual-operator-call.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/clang/test/CodeGenCXX/virtual-operator-call.cpp b/clang/test/CodeGenCXX/virtual-operator-call.cpp new file mode 100644 index 00000000000..018052bb472 --- /dev/null +++ b/clang/test/CodeGenCXX/virtual-operator-call.cpp @@ -0,0 +1,10 @@ +// RUN: clang-cc %s -emit-llvm -o - | FileCheck %s + +struct A { + virtual int operator-() = 0; +}; + +void f(A *a) { + // CHECK: call i32 % + -*a; +} |