[PATCH] D128113: Clang: fix AST representation of expanded template arguments.

Matheus Izvekov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sat Aug 27 10:56:42 PDT 2022


mizvekov added a comment.

In D128113#3753656 <https://reviews.llvm.org/D128113#3753656>, @davrec wrote:

> If I'm missing something and it is substantially more complex than that, then you're right that storing the pack index might end up the best solution - we don't want to e.g. have to do considerable Sema logic in the Resugarer just to infer the pack index.

Having a new Subst-like node that wraps the whole expanded pattern seems to simplify the case where we need to take the type apart, such as deductions, leaving you without the 'birds-eye' view. Otherwise we would need to dig into the type to figure out what pack indexes we need to preserve in the resulting type.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D128113/new/

https://reviews.llvm.org/D128113



More information about the cfe-commits mailing list