[clangd] add inlay hints for std::forward-ed parameter packs
This adds special-case treatment for parameter packs in make_unique-like functions to forward parameter names to inlay hints. The parameter packs are being resolved recursively by traversing the function body of forwarding functions looking for expressions matching the (std::forwarded) parameters expanded from a pack. The implementation checks whether parameters are being passed by (rvalue) reference or value and adds reference inlay hints accordingly. The traversal has a limited recursion stack depth, and recursive calls like std::make_tuple are cut off to avoid hinting duplicate parameter names. Reviewed By: sammccall Differential Revision: https://reviews.llvm.org/D124690
Loading
Please sign in to comment