[clang] [clang] Fix high memory consumption during pack deduction (PR #88637)
via cfe-commits
cfe-commits at lists.llvm.org
Mon Apr 15 03:53:06 PDT 2024
================
@@ -831,7 +831,7 @@ class PackDeductionScope {
if (IsPartiallyExpanded)
PackElements += NumPartialPackArgs;
else if (IsExpanded)
- PackElements += *FixedNumExpansions;
+ PackElements += FixedNumExpansions.value_or(1);
----------------
Sirraide wrote:
> I assumed the template parameter not being a pack is a valid case and not a bug.
Yeah, I’m unfortunately not familiar enough w/ this part of Clang to comment on whether that’s the case or not; I’d have to look into this a bit more.
CC @AaronBallman, @erichkeane
https://github.com/llvm/llvm-project/pull/88637
More information about the cfe-commits
mailing list