todo : add comparison function for custom types