From f111d935722ed488144600cea5ed03a6b5069e8f Mon Sep 17 00:00:00 2001 From: Peter Collingbourne Date: Fri, 15 Apr 2011 00:35:48 +0000 Subject: C1X: implement generic selections As an extension, generic selection support has been added for all supported languages. The syntax is the same as for C1X. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129554 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/CGExprConstant.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lib/CodeGen/CGExprConstant.cpp') diff --git a/lib/CodeGen/CGExprConstant.cpp b/lib/CodeGen/CGExprConstant.cpp index 3a2fb9bd9d..8e26b206eb 100644 --- a/lib/CodeGen/CGExprConstant.cpp +++ b/lib/CodeGen/CGExprConstant.cpp @@ -457,6 +457,10 @@ public: return Visit(PE->getSubExpr()); } + llvm::Constant *VisitGenericSelectionExpr(GenericSelectionExpr *GE) { + return Visit(GE->getResultExpr()); + } + llvm::Constant *VisitCompoundLiteralExpr(CompoundLiteralExpr *E) { return Visit(E->getInitializer()); } -- cgit v1.2.3