Author: spouliot
Date: 2008-02-16 16:02:56 -0500 (Sat, 16 Feb 2008)
New Revision: 95922
Modified:
trunk/mono-tools/gendarme/rules/Gendarme.Rules.Design/ChangeLog
trunk/mono-tools/gendarme/rules/Gendarme.Rules.Design/TypesWithDisposableFieldsShouldBeDisposableRule.cs
Log:
2008-02-16 Sebastien Pouliot <[EMAIL PROTECTED]>
* TypesWithDisposableFieldsShouldBeDisposableRule.cs: Don't check
code generated by compilers or tools since the developer cannot do
(much) on them.
Modified: trunk/mono-tools/gendarme/rules/Gendarme.Rules.Design/ChangeLog
===================================================================
--- trunk/mono-tools/gendarme/rules/Gendarme.Rules.Design/ChangeLog
2008-02-16 21:01:33 UTC (rev 95921)
+++ trunk/mono-tools/gendarme/rules/Gendarme.Rules.Design/ChangeLog
2008-02-16 21:02:56 UTC (rev 95922)
@@ -1,3 +1,9 @@
+2008-02-16 Sebastien Pouliot <[EMAIL PROTECTED]>
+
+ * TypesWithDisposableFieldsShouldBeDisposableRule.cs: Don't check
+ code generated by compilers or tools since the developer cannot do
+ (much) on them.
+
2008-02-15 Sebastien Pouliot <[EMAIL PROTECTED]>
* AvoidEmptyInterfaceRule.cs: Oops, wrong/duplicate rule.
Modified:
trunk/mono-tools/gendarme/rules/Gendarme.Rules.Design/TypesWithDisposableFieldsShouldBeDisposableRule.cs
===================================================================
---
trunk/mono-tools/gendarme/rules/Gendarme.Rules.Design/TypesWithDisposableFieldsShouldBeDisposableRule.cs
2008-02-16 21:01:33 UTC (rev 95921)
+++
trunk/mono-tools/gendarme/rules/Gendarme.Rules.Design/TypesWithDisposableFieldsShouldBeDisposableRule.cs
2008-02-16 21:02:56 UTC (rev 95922)
@@ -51,7 +51,7 @@
public RuleResult CheckType (TypeDefinition type)
{
// rule doesn't apply to enums, interfaces or structs
- if (type.IsEnum || type.IsInterface || type.IsValueType)
+ if (type.IsEnum || type.IsInterface || type.IsValueType
|| type.IsGeneratedCode ())
return RuleResult.DoesNotApply;
MethodDefinition explicitDisposeMethod = null;
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches