注意区分C++与JAVA在编程细节的区别: 错误代码: bool operator < (const AssetInfo& ai) const//升序 { if (m_wwwcharacter != ai.m_wwwcharacter) return stod<int>(m_wwwcharacter) - stod<int>(ai.m_wwwcharacter) ; if (m_time != ai.m_time) return stod<long>(m_time) - stod<long>(ai.m_time) ; } 正确代码: bool operator < (const AssetInfo& ai) const//升序 { if (m_wwwcharacter != ai.m_wwwcharacter) return stod<int>(m_wwwcharacter) - stod<int>(ai.m_wwwcharacter) < 0; if (m_time != ai.m_time) return stod<long>(m_time) - stod<long>(ai.m_time) < 0; }