aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGExprScalar.cpp
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2009-09-15 04:39:46 +0000
committerAnders Carlsson <andersca@mac.com>2009-09-15 04:39:46 +0000
commitc1eb14a66fdd955aff3f957a5843295f27952bdd (patch)
treeab3738d62044635456c762d297cfef49bbce19e1 /lib/CodeGen/CGExprScalar.cpp
parentaab7efef16e29797e9a7fe4a8e93ad7f58752991 (diff)
Codegen support for nullptr from C++0x.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81835 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGExprScalar.cpp')
-rw-r--r--lib/CodeGen/CGExprScalar.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/CodeGen/CGExprScalar.cpp b/lib/CodeGen/CGExprScalar.cpp
index aee5446434..7f9b66468b 100644
--- a/lib/CodeGen/CGExprScalar.cpp
+++ b/lib/CodeGen/CGExprScalar.cpp
@@ -308,6 +308,10 @@ public:
return 0;
}
+ Value *VisitCXXNullPtrLiteralExpr(const CXXNullPtrLiteralExpr *E) {
+ return llvm::Constant::getNullValue(ConvertType(E->getType()));
+ }
+
// Binary Operators.
Value *EmitMul(const BinOpInfo &Ops) {
if (CGF.getContext().getLangOptions().OverflowChecking