Permalink
Browse files

Stop walking the tree when we hit System.Attribute

  • Loading branch information...
1 parent 68df5f3 commit d62e9aa3ad047456bfce443dee86e684782df994 @krijesta krijesta committed Feb 15, 2012
@@ -117,7 +117,8 @@ public RuleResult CheckType (TypeDefinition type)
allProperties.Add (property.Name);
}
}
- } while (t.BaseType != null && (t = t.BaseType.Resolve()) != null);
+ t = t.BaseType != null ? t.BaseType.Resolve() : null;
+ } while (t != null && !t.IsNamed("System", "Attribute"));
// look through parameters
foreach (MethodDefinition constructor in type.Methods) {

0 comments on commit d62e9aa

Please sign in to comment.