Hi, everyone.
I am stuck in such a situation:
When failing to open a file, of which the name is in Unicode, I need to show the user something like "Can't open file: \My Document\file-name-in-unicode.txt" by throwing an exception . I often use exceptions this way(is this a good way?).
I am on Windows Mobile, and everything string is in Unicode. I would like to use all the C++ features in my program and when I tried the standard exception classes, I was stuck. the standard exception classes does not support Unicode. I know this is because the C++ language was designed before Unicode was ever a major thing. The exception classes are not designed using template, the what() function only returns a char*.
So, I am just seeking a workaroud, how would you do when using std::exception (either deriving from it or just using its subclasses) with Unicode?