I have my own class that represents a custom string class. I\'m using VS2012RC. I have overloaded some operators of my class CustomString.
Here\'s some code:
You have to use printf("%s\n", str.c_str());. %s expects a char array and you gave it a CustomString object which is something different. You have to get char array from the string by calling c_str() function.
printf("%s\n", str.c_str());
%s
CustomString
c_str()