void f(wchar_t const* s)
{
pan::log_DEBUG("f(s=", pan::w2m(s), ")");
. . .
}
the new facilities allow passing wide string class instances, as in:
void f(std::string const& s)
{
pan::log_DEBUG("f(s=", pan::w2m(s), ")");
. . .
}
and
void f(stlsoft::simple_wstring const& s)
{
pan::log_DEBUG("f(s=", pan::w2m(s), ")");
. . .
}
Previously, the log statement would have to explicitly elicit the C-string pointer and the length, as in:
void f(stlsoft::simple_wstring const& s)
{
pan::log_DEBUG("f(s=", pan::w2m(s.data(), s.length()), ")");
. . .
}
Obviously, this is far less expressive than the new facilities.
Thanks for the Pantheios library Matt. Simply one of the best pieces of software I have come across. I wonder if you have a tutorial/sample that shows how to use the inserter classes from a fixed back-end DLL (that you illustrate here: http://sourceforge.net/projects/pantheios/forums/forum/647484/topic/1639420). Thanks.
ReplyDeleteHi
ReplyDeleteThanks for the feedback. (And apologies for not writing sooner.)
Unfortunately, for most of this year I have been incredibly busy on a commercial engagement. That ends in four weeks' time, after which I will be doing a lot of work to do a non-beta release of Pantheios, including new logo, website, packaging, and much tutorial information.
Matt