bool Sema::ActOnObjectArraySpec(ASTContext &C, SourceLocation Loc, DeclSpec &DS, ArrayRef<ArraySpec*> Dimensions) { if(!DS.hasAttributeSpec(DeclSpec::AS_dimension)) DS.setAttributeSpec(DeclSpec::AS_dimension); DS.setDimensions(Dimensions); return false; }
bool Sema::ActOnAttrSpec(SourceLocation Loc, DeclSpec &DS, DeclSpec::AS Val) { if (DS.hasAttributeSpec(Val)) { Diags.Report(Loc, diag::err_duplicate_attr_spec) << DeclSpec::getSpecifierName(Val); return true; } DS.setAttributeSpec(Val); return false; }
bool Sema::ActOnDimensionAttrSpec(ASTContext &C, SourceLocation Loc, DeclSpec &DS, ArrayRef<ArraySpec*> Dimensions) { if (DS.hasAttributeSpec(DeclSpec::AS_dimension)) { Diags.Report(Loc, diag::err_duplicate_attr_spec) << DeclSpec::getSpecifierName(DeclSpec::AS_dimension); return true; } DS.setAttributeSpec(DeclSpec::AS_dimension); DS.setDimensions(Dimensions); return false; }