#include "clang/AST/DeclCXX.h"
#include "clang/AST/DeclTemplate.h"
#include "clang/AST/Expr.h"
+#include "clang/AST/ExprCXX.h"
#include "clang/AST/ASTContext.h"
#include "clang/AST/TypeLoc.h"
#include "clang/AST/ASTMutationListener.h"
NTTP->getType().getNonLValueExprType(Context),
Expr::getValueKindForType(NTTP->getType()),
NTTP->getLocation());
- // FIXME: Variadic templates.
+
+ if (NTTP->isParameterPack())
+ E = new (Context) PackExpansionExpr(Context.DependentTy, E,
+ NTTP->getLocation());
Arg = TemplateArgument(E);
} else {
TemplateTemplateParmDecl *TTP = cast<TemplateTemplateParmDecl>(*Param);
int check3[sum<1, 2, 3, 4, 5>::value == 15? 1 : -1];
-#if 0
- // FIXME: Instantiation of this fails.
template<int ... Values>
struct lazy_sum {
int operator()() {
void f() {
lazy_sum<1, 2, 3, 4, 5>()();
}
-#endif
}
namespace Indices {