[clang] [Clang][C++26] Implement Pack Indexing (P2662R3). (PR #72644)

Erich Keane via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 9 10:21:21 PST 2024


================
@@ -5697,6 +5698,39 @@ QualType ASTContext::getDecltypeType(Expr *e, QualType UnderlyingType) const {
   return QualType(dt, 0);
 }
 
+QualType ASTContext::getPackIndexingType(QualType Pattern, Expr *IndexExpr,
+                                         bool FullyExpanded,
+                                         ArrayRef<QualType> Expansions,
+                                         int Index) const {
+  QualType Canonical;
+  if (FullyExpanded && Index != -1) {
----------------
erichkeane wrote:

What does 'FullyExpanded' mean here?  Do we mean 'fully instantiated'?  If so, I would expect some level of `IndexExpr->EvaluateKnownConstInt` or something to be here instead of Index?

https://github.com/llvm/llvm-project/pull/72644


More information about the cfe-commits mailing list