summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaTemplate/pack-deduction.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Always deduce the lengths of contained parameter packs when deducing aRichard Smith2020-01-061-2/+2
| | | | | | | | | | | | | | | | | pack expansion. Previously, if all parameter / argument pairs for a pack expansion deduction were non-deduced contexts, we would not deduce the arity of the pack, and could end up deducing a different arity (leading to failures during substitution) or defaulting to an arity of 0 (leading to bad diagnostics about passing the wrong number of arguments to a variadic function). Instead, we now always deduce the arity for all involved packs any time we deduce a pack expansion. This will result in less substitution happening in some cases, which could avoid non-SFINAEable errors, and should generally improve the quality of diagnostics when passing initializer lists to variadic functions.
* Remove an assert in template pack deduction during nested instantiation.Richard Trieu2019-03-151-0/+19
| | | | llvm-svn: 356231
* Fix failing testcase to actually be valid.Richard Smith2018-07-191-1/+1
| | | | llvm-svn: 337483
* Fix template argument deduction when a parameter pack has a valueRichard Smith2018-07-191-0/+101
| | | | | | | | | | | | | | provided by an outer template. We made the incorrect assumption in various places that the only way we can have any arguments already provided for a pack during template argument deduction was from a partially-specified pack. That's not true; we can also have arguments from an enclosing already-instantiated template, and that can even result in the function template's own pack parameters having a fixed length and not being packs for the purposes of template argument deduction. llvm-svn: 337481
* PR14615: add (passing) tests for this already-fixed bugRichard Smith2014-07-221-0/+28
| | | | llvm-svn: 213709
* Retain an expression pack expansion when the parameter pack expansion code asksRichard Smith2014-06-061-0/+7
| | | | | | us to. llvm-svn: 210355
* PR14841: If partial substitution of explicitly-specified template argumentsRichard Smith2014-06-061-0/+12
| | | | | | | | results in a template having too many arguments, but all the trailing arguments are packs, that's OK if we have a partial pack substitution: the trailing pack expansions may end up empty. llvm-svn: 210350
* PR19878: If a pack expansion appears within another pack expansion, correctlyRichard Smith2014-05-291-0/+20
deduce any packs that are expanded by both expansions. llvm-svn: 209786
OpenPOWER on IntegriCloud