
On 16 August 2011 01:08, Dave Abrahams <dave@boostpro.com> wrote:
on Sat Aug 13 2011, Daniel James <dnljms-AT-gmail.com> wrote:
On 13 August 2011 19:02, Dave Abrahams <dave@boostpro.com> wrote:
I think I agree with Artyom here. *Somebody* has to decide how that datatype will be interpreted when we receive it. Unless we refuse altogether to accept std::string in our interfaces (which sounds like a bad idea to me), why not make the decision that it's UTF-8?
Because if the native encoding isn't UTF-8 that will give the wrong result for cases such as:
int main(int argc, char** argv) { // .... boost::filesystem::path p(argv[0]);
? I don't see any std::string here. Is there an implicit conversion?
Well no, but it'd be an odd choice to make this do something different (wrt. the encoding of the argument): int main(int argc, char** argv) { std::vector<std::string> arguments( argv, argv + argc); // .... boost::filesystem::path p(arguments[0]);