[python] relative operators export

Let's say I've got class A {...} and I've implemented operator<(A,A). How can I export all the operators similarly to what boost::operators doing in one shot? Gennadiy

on Fri Nov 16 2007, Gennadiy Rozental
Let's say I've got class A {...} and I've implemented operator<(A,A).
How can I export all the operators similarly to what boost::operators doing in one shot?
Write a function template that exports each one, then use that over and over. HTH, -- Dave Abrahams Boost Consulting http://www.boost-consulting.com

David Abrahams
writes: on Fri Nov 16 2007, Gennadiy Rozental
wrote: Let's say I've got class A {...} and I've implemented operator<(A,A).
How can I export all the operators similarly to what boost::operators doing in one shot?
Write a function template that exports each one, then use that over and over.
HTH,
Why can't this be done inside the library. This looks like it should have some demand. Gennadiy

on Sat Nov 17 2007, Gennadiy Rozental
David Abrahams
writes: on Fri Nov 16 2007, Gennadiy Rozental
wrote: Let's say I've got class A {...} and I've implemented operator<(A,A).
How can I export all the operators similarly to what boost::operators doing in one shot?
Write a function template that exports each one, then use that over and over.
HTH,
Why can't this be done inside the library.
Nobody wrote, documented, and tested it.
This looks like it should have some demand.
You're the first who's asked for it. -- Dave Abrahams Boost Consulting http://www.boost-consulting.com
participants (2)
-
David Abrahams
-
Gennadiy Rozental