summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGExprConstant.cpp
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2009-10-18 20:31:03 +0000
committerAnders Carlsson <andersca@mac.com>2009-10-18 20:31:03 +0000
commit9500ad13b0b22bc5e8730aa1d3472f9f5349fefd (patch)
treeaf9b821b4c68eb992de8452a74adfe73b92151e5 /clang/lib/CodeGen/CGExprConstant.cpp
parent70e7eadd15506498a909b3ea2bd984e987cc2667 (diff)
downloadbcm5719-llvm-9500ad13b0b22bc5e8730aa1d3472f9f5349fefd.tar.gz
bcm5719-llvm-9500ad13b0b22bc5e8730aa1d3472f9f5349fefd.zip
Use CK_BitCast for member function pointer casts. Fixes PR5138.
llvm-svn: 84438
Diffstat (limited to 'clang/lib/CodeGen/CGExprConstant.cpp')
-rw-r--r--clang/lib/CodeGen/CGExprConstant.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGExprConstant.cpp b/clang/lib/CodeGen/CGExprConstant.cpp
index 7f540c3c068..fc3748c8e3c 100644
--- a/clang/lib/CodeGen/CGExprConstant.cpp
+++ b/clang/lib/CodeGen/CGExprConstant.cpp
@@ -542,7 +542,11 @@ public:
return CS;
}
}
-
+
+ case CastExpr::CK_BitCast:
+ // This must be a member function pointer cast.
+ return Visit(E->getSubExpr());
+
default: {
// FIXME: This should be handled by the CK_NoOp cast kind.
// Explicit and implicit no-op casts
OpenPOWER on IntegriCloud