[great-users] Small bug - SetStrValue is not checked...

Tivadar Szemethy tiv at isis.vanderbilt.edu
Wed Apr 7 16:24:42 CDT 2004


> How about the "1-step silent type conversion" feature of C++?
> I'm sure that "string" has a constructor "string(const char*)" and 0
> type-matches const char*.
> Try this:
> #include <string>
> 
> void foo(const std::string & clunk)
> {
> 	std::string me = clunk;
> }
> 
> void bar()
> {
> 	foo(0);
> }

I realized I mistyped the function to GetStrValue (not for the first time...)
and that's why I got to the wrong conclusion.

Sorry for the bum steer,

Tivadar


More information about the great-users mailing list