In C#, is there a way to overload comparison operators such as ==
, =<
or>
on a user-defined object?
Similar to how yo can write "string"=="string"
instead of "string".Equals("string")
I know you can define the CompareTo and Equals functions but I was wondering if there was a shortcut.