r304000 - Adding a const overload of DesignatedInitExpr::getDesignator().

Aaron Ballman via cfe-commits cfe-commits at lists.llvm.org
Fri May 26 08:55:52 PDT 2017


Author: aaronballman
Date: Fri May 26 10:55:52 2017
New Revision: 304000

URL: http://llvm.org/viewvc/llvm-project?rev=304000&view=rev
Log:
Adding a const overload of DesignatedInitExpr::getDesignator().

Modified:
    cfe/trunk/include/clang/AST/Expr.h

Modified: cfe/trunk/include/clang/AST/Expr.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/Expr.h?rev=304000&r1=303999&r2=304000&view=diff
==============================================================================
--- cfe/trunk/include/clang/AST/Expr.h (original)
+++ cfe/trunk/include/clang/AST/Expr.h Fri May 26 10:55:52 2017
@@ -4284,6 +4284,9 @@ public:
   }
 
   Designator *getDesignator(unsigned Idx) { return &designators()[Idx]; }
+  const Designator *getDesignator(unsigned Idx) const {
+    return &designators()[Idx];
+  }
 
   void setDesignators(const ASTContext &C, const Designator *Desigs,
                       unsigned NumDesigs);




More information about the cfe-commits mailing list