Fix #217
This commit is contained in:
parent
74dd63e723
commit
7a80c0f643
|
@ -42,29 +42,30 @@ class UndocumentedDeclarationCheck : BaseAnalyzer
|
||||||
setOverride(true);
|
setOverride(true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
|
||||||
|
bool shouldPop = false;
|
||||||
|
bool prevOverride = getOverride();
|
||||||
|
bool ovr = false;
|
||||||
|
foreach (attribute; dec.attributes)
|
||||||
{
|
{
|
||||||
bool shouldPop = false;
|
shouldPop = dec.attributeDeclaration !is null;
|
||||||
bool prevOverride = getOverride();
|
if (isProtection(attribute.attribute.type))
|
||||||
bool ovr = false;
|
|
||||||
foreach (attribute; dec.attributes)
|
|
||||||
{
|
{
|
||||||
if (isProtection(attribute.attribute.type))
|
if (dec.attributeDeclaration)
|
||||||
{
|
set(attribute.attribute.type);
|
||||||
shouldPop = true;
|
else
|
||||||
push(attribute.attribute.type);
|
push(attribute.attribute.type);
|
||||||
}
|
|
||||||
else if (attribute.attribute == tok!"override")
|
|
||||||
ovr = true;
|
|
||||||
}
|
}
|
||||||
if (ovr)
|
else if (attribute.attribute == tok!"override")
|
||||||
setOverride(true);
|
ovr = true;
|
||||||
dec.accept(this);
|
|
||||||
if (shouldPop)
|
|
||||||
pop();
|
|
||||||
if (ovr)
|
|
||||||
setOverride(prevOverride);
|
|
||||||
}
|
}
|
||||||
|
if (ovr)
|
||||||
|
setOverride(true);
|
||||||
|
dec.accept(this);
|
||||||
|
if (shouldPop)
|
||||||
|
pop();
|
||||||
|
if (ovr)
|
||||||
|
setOverride(prevOverride);
|
||||||
}
|
}
|
||||||
|
|
||||||
override void visit(const VariableDeclaration variable)
|
override void visit(const VariableDeclaration variable)
|
||||||
|
|
Loading…
Reference in New Issue