Author: spouliot
Date: 2008-02-17 16:00:55 -0500 (Sun, 17 Feb 2008)
New Revision: 96000
Modified:
trunk/mono-tools/gendarme/rules/Gendarme.Rules.Serialization/MissingSerializableAttributeOnISerializableTypeRule.cs
Log:
Modified:
trunk/mono-tools/gendarme/rules/Gendarme.Rules.Serialization/MissingSerializableAttributeOnISerializableTypeRule.cs
===================================================================
---
trunk/mono-tools/gendarme/rules/Gendarme.Rules.Serialization/MissingSerializableAttributeOnISerializableTypeRule.cs
2008-02-17 21:00:23 UTC (rev 95999)
+++
trunk/mono-tools/gendarme/rules/Gendarme.Rules.Serialization/MissingSerializableAttributeOnISerializableTypeRule.cs
2008-02-17 21:00:55 UTC (rev 96000)
@@ -41,8 +41,9 @@
public RuleResult CheckType (TypeDefinition type)
{
- // [Serializable] is not applicable to interfaces
- if (type.IsInterface)
+ // rule does not apply to interface (since
[Serializable] is not applicable to interfaces)
+ // nor does it apply to delegates
+ if (type.IsInterface || type.IsDelegate ())
return RuleResult.DoesNotApply;
// rule does not apply if the type does not implements
ISerializable
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches