operator overloading

Joined
May 18, 2011
Messages
1
Reaction score
0
hi,:lol:
I have added a special hardware to my cpu and now I want to overload * for double type.
usually [ double operator*(double, double) ] does not work because double is a predefined system type.
changing all of code manually is not a good way for me so I want to find an automatic way.
first solution I tried was to define a class with one double variable inside. then overload * for that class, but it is not good because it has a lot of timing overhead , moreover I should carefully change all of my code to replace double with new type.

is there any way to overload * operator for type of Double? can macros help me ?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,534
Members
45,007
Latest member
OrderFitnessKetoCapsules

Latest Threads

Top