From 9f35c413f5ef37ff112db2592d130218fd81c1ee Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sat, 28 Feb 2004 17:41:48 +0000 Subject: [PATCH] Do not remove an active template argument even if the superclass had one of the same name llvm-svn: 11950 --- utils/TableGen/FileParser.y | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/utils/TableGen/FileParser.y b/utils/TableGen/FileParser.y index d0f88c30c04..4731674e521 100644 --- a/utils/TableGen/FileParser.y +++ b/utils/TableGen/FileParser.y @@ -467,7 +467,8 @@ ObjectBody : OptID { for (unsigned i = 0, e = $4->size(); i != e; ++i) { Record *SuperClass = (*$4)[i].first; for (unsigned i = 0, e = SuperClass->getTemplateArgs().size(); i != e; ++i) - CurRec->removeValue(SuperClass->getTemplateArgs()[i]); + if (!CurRec->isTemplateArg(SuperClass->getTemplateArgs()[i])) + CurRec->removeValue(SuperClass->getTemplateArgs()[i]); } delete $4; // Delete the class list...