> I've done this before as well. > But it's a very simple function. > And I assume TestAutoSelect is a macro. > Can I take a look at the code?
Yes, TextAutoSelect is a macro, because without using a macro, there is no way to generate a wchar_t string literal (prefixed with L) from a char string literal at compile time. The macro also hides a bit of template code which is used for type detection purposes. I have uploaded the code to: http://groups.yahoo.com/group/boost/files/TextSelector.hpp It's directly copied from the project it's residing in, so please don't pay any attention to the namespace naming conventions. I have successfully compiled this code using VC++ 7.1, Intel C++ 7.1, gcc 2.95.3-6 (mingw32) on Windows, and gcc 3.20 on Linux. Let me know what you think. Ehsan _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost