feat: add requires clause for totally ordered keys in SmallMap

Signed-off-by: szdytom <szdytom@qq.com>
This commit is contained in:
方而静 2025-08-04 16:18:27 +08:00
parent 8d0a6ca6f5
commit e1d3725b87
Signed by: szTom
GPG Key ID: 072D999D60C6473C

View File

@ -21,6 +21,7 @@ namespace istd {
* @tparam T_Value Type of the value. * @tparam T_Value Type of the value.
*/ */
template<typename T_Key, typename T_Value> template<typename T_Key, typename T_Value>
requires std::totally_ordered<T_Key>
class SmallMap { class SmallMap {
/** /**
* @brief Internal entry structure for key-value pairs. * @brief Internal entry structure for key-value pairs.