Fix false positive in builtin property name checker
This commit is contained in:
parent
abd6409519
commit
75970e5e57
|
@ -45,6 +45,14 @@ class BuiltinPropertyNameCheck : BaseAnalyzer
|
||||||
fd.accept(this);
|
fd.accept(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override void visit(const FunctionBody functionBody)
|
||||||
|
{
|
||||||
|
int d = depth;
|
||||||
|
scope(exit) depth = d;
|
||||||
|
depth = 0;
|
||||||
|
functionBody.accept(this);
|
||||||
|
}
|
||||||
|
|
||||||
override void visit(const AutoDeclaration ad)
|
override void visit(const AutoDeclaration ad)
|
||||||
{
|
{
|
||||||
if (depth > 0) foreach (i; ad.identifiers)
|
if (depth > 0) foreach (i; ad.identifiers)
|
||||||
|
|
Loading…
Reference in New Issue