Removing redundant code

This commit is contained in:
Chris Cameron
2018-03-15 16:21:55 -04:00
parent 49a2b6875d
commit f11f049189

View File

@@ -4,37 +4,8 @@ namespace ICD.Common.Utils.Attributes
{ {
/// <summary> /// <summary>
/// AbstractIcdAttribute is the base class for all ICD attributes. /// AbstractIcdAttribute is the base class for all ICD attributes.
/// It provides a global cache for looking up symbols via an attribute type.
/// </summary> /// </summary>
public abstract class AbstractIcdAttribute : Attribute public abstract class AbstractIcdAttribute : Attribute
{ {
private readonly int m_HashCode;
#region Constructors
/// <summary>
/// Constructor.
/// </summary>
protected AbstractIcdAttribute()
{
// Duplicate attributes (E.g. [A, A]) are considered to be the same instance by reflection.
// We get around this by using a GUID for the hash code.
m_HashCode = Guid.NewGuid().GetHashCode();
}
#endregion
#region Methods
/// <summary>
/// Gets the hash code for the instance.
/// </summary>
/// <returns></returns>
public override int GetHashCode()
{
return m_HashCode;
}
#endregion
} }
} }