This commit is contained in:
Hackerpilot 2015-01-05 17:52:10 -08:00
parent 74dd63e723
commit 7a80c0f643
1 changed files with 19 additions and 18 deletions

View File

@ -42,16 +42,18 @@ class UndocumentedDeclarationCheck : BaseAnalyzer
setOverride(true); setOverride(true);
} }
} }
else
{
bool shouldPop = false; bool shouldPop = false;
bool prevOverride = getOverride(); bool prevOverride = getOverride();
bool ovr = false; bool ovr = false;
foreach (attribute; dec.attributes) foreach (attribute; dec.attributes)
{ {
shouldPop = dec.attributeDeclaration !is null;
if (isProtection(attribute.attribute.type)) if (isProtection(attribute.attribute.type))
{ {
shouldPop = true; if (dec.attributeDeclaration)
set(attribute.attribute.type);
else
push(attribute.attribute.type); push(attribute.attribute.type);
} }
else if (attribute.attribute == tok!"override") else if (attribute.attribute == tok!"override")
@ -65,7 +67,6 @@ class UndocumentedDeclarationCheck : BaseAnalyzer
if (ovr) if (ovr)
setOverride(prevOverride); setOverride(prevOverride);
} }
}
override void visit(const VariableDeclaration variable) override void visit(const VariableDeclaration variable)
{ {