Added IsEqual function to Primitive class