Added support for the GCC "unavailable" attribute.

This commit is contained in:
Erik Verbruggen
2010-05-26 13:49:06 +02:00
parent 9e89f36cd9
commit 51fbf9695c
5 changed files with 22 additions and 1 deletions

View File

@@ -439,8 +439,12 @@ bool CheckSpecifier::visit(TypeofSpecifierAST *ast)
bool CheckSpecifier::visit(AttributeAST *ast)
{
if (ast->identifier_token) {
if (identifier(ast->identifier_token) == control()->deprecatedId())
const Identifier *id = identifier(ast->identifier_token);
if (id == control()->deprecatedId())
_fullySpecifiedType.setDeprecated(true);
else if (id == control()->unavailableId())
_fullySpecifiedType.setUnavailable(true);
}
return false;
}