Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试转换8/17/2003为boot::gregorian::date使用以下代码
8/17/2003
boot::gregorian::date
std::string test = "08/17/2013"; date d(from_simple_string(test));
但是我得到一个未处理的异常关于如何完成这个的任何建议?
从提升示例:
// The following date is in ISO 8601 extended format (CCYY-MM-DD) std::string s("2001-10-9"); //2001-October-09 date d(from_simple_string(s)); std::cout << to_simple_string(d) << std::endl;
你的格式不正确。