QualType Type, SourceLocation BLoc,
SourceLocation RP) :
Expr(ShuffleVectorExprClass, Type), BuiltinLoc(BLoc),
- RParenLoc(RP), NumExprs(nexpr)
- {
+ RParenLoc(RP), NumExprs(nexpr) {
+
SubExprs = new Expr*[nexpr];
for (unsigned i = 0; i < nexpr; i++)
SubExprs[i] = args[i];
static bool classof(const ShuffleVectorExpr *) { return true; }
~ShuffleVectorExpr() {
- for (unsigned i = 0; i < NumExprs; i++)
- delete SubExprs[i];
delete [] SubExprs;
}
void Stmt::Destroy(ASTContext& C) {
DestroyChildren(C);
- this->~Stmt();
+ // FIXME: Eventually all Stmts should be allocated with the allocator
+ // in ASTContext, just like with Decls.
+ // this->~Stmt();
+ delete this;
}
void Stmt::PrintStats() {