C++ function signature: Allow most specifiers to be replaced.

Except for some SimpleSpecifiers and AttributeSpecifiers. Fixes a bug
where NamedTypeSpecifiers would not be replaced when the return type
was adjusted.

Change-Id: Ie093615ebf1b26d181b888fcbcc341e5bdf85fd1
Reviewed-on: http://codereview.qt-project.org/4749
Reviewed-by: Leandro T. C. Melo <leandro.melo@nokia.com>
This commit is contained in:
Christian Kamm
2011-09-13 11:36:05 +02:00
parent 72056e3570
commit fc7dae4096

View File

@@ -455,7 +455,9 @@ static bool canReplaceSpecifier(TranslationUnit *translationUnit, SpecifierAST *
return false;
}
}
return false;
if (specifier->asAttributeSpecifier())
return false;
return true;
}
static SpecifierAST *findFirstReplaceableSpecifier(TranslationUnit *translationUnit, SpecifierListAST *list)