forked from boostorg/conversion
@ -13,12 +13,26 @@
|
||||
#include <boost/static_assert.hpp>
|
||||
#include <boost/lexical_cast.hpp>
|
||||
|
||||
#include <boost/date_time/gregorian/gregorian.hpp>
|
||||
#include <boost/date_time/posix_time/posix_time.hpp>
|
||||
|
||||
void parseDate()
|
||||
{
|
||||
std::locale locale;
|
||||
boost::date_time::format_date_parser<boost::gregorian::date, wchar_t> parser(L"", locale);
|
||||
boost::date_time::special_values_parser<boost::gregorian::date, wchar_t> svp;
|
||||
|
||||
boost::gregorian::date date = parser.parse_date(L"", L"", svp);
|
||||
}
|
||||
|
||||
|
||||
int main()
|
||||
{
|
||||
#ifdef BOOST_MSVC
|
||||
BOOST_STATIC_ASSERT((boost::is_same<wchar_t, unsigned short>::value));
|
||||
#endif
|
||||
|
||||
parseDate();
|
||||
return ::boost::lexical_cast<int>(L"1000") == 1000;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user