Operator Overloading
Posted: Wed Aug 17, 2011 5:24 pm
Is there an easy way to overload operators/functions in Emacs Lisp?
I'd like to overload + to handle custom-defined data types, other than "normal" numerics.
What I'd like to do is write a procedure that checks the types of the arguments, and if they're my custom-defined types, then perform the custom defined operations I define, and otherwise return handling to the "normal" implementation of +.
I'd like to overload + to handle custom-defined data types, other than "normal" numerics.
What I'd like to do is write a procedure that checks the types of the arguments, and if they're my custom-defined types, then perform the custom defined operations I define, and otherwise return handling to the "normal" implementation of +.