2010/2/3 Alan Tennant <alan2here@gmail.com>
I get an error that points me to this page http://stlab.adobe.com/wiki/index.php/Troubleshooting
Probably because I'm using VC++9 not 8.
Just to clarify I meant this.
std::string s1 = "1234";
std::cout<<s1.length(); // couts 4
adobe::polly p1;
p1 = s1;
std::cout<<p1.length(); // not necessarily this exact syntax. couts 4
std::string s2;
s2 = polly_cast<std::string>(p1);
std::cout<<s2;
The syntax is more like this:
poly<ostreamable> p;
p = 42;
cout << p; // writes "42"
p = "hello";
cout << p; // writes "hello";
p = vector<int>(); // does not compile, because vector<int> is not ostreamable.
Note that you should implement ostreamable.
So it's not going to be safe as in "type safe" but it may well be perfectly safe.
I don't understand this.
Roman Perepelitsa.