borromeotlhs / amop

Automatically exported from code.google.com/p/amop
0 stars 0 forks source link

Missing operator T& on MockObject<T> #19

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Try to compile static_cast<std::string&>(MockObject<std::string>())
2.
3.

What is the expected output? What do you see instead?

What version of the product are you using? On what operating system?

Please provide any additional information below.

Add operator T& to MockObject<T>:

        operator T&()
        {
            return *((T*)getVptr());
        }

Original issue reported on code.google.com by blu...@telia.com on 30 Dec 2009 at 3:37