From 75970e5e575f549b1f8a6407e7075191f3170210 Mon Sep 17 00:00:00 2001 From: Hackerpilot Date: Fri, 22 Aug 2014 14:32:12 -0700 Subject: [PATCH] Fix false positive in builtin property name checker --- analysis/builtin_property_names.d | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/analysis/builtin_property_names.d b/analysis/builtin_property_names.d index 5ba02e3..a5ff956 100644 --- a/analysis/builtin_property_names.d +++ b/analysis/builtin_property_names.d @@ -45,6 +45,14 @@ class BuiltinPropertyNameCheck : BaseAnalyzer 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) { if (depth > 0) foreach (i; ad.identifiers)