浏览代码

Restore implicit conversion

Ivan Savenko 2 年之前
父节点
当前提交
f1032063bc
共有 1 个文件被更改,包括 5 次插入0 次删除
  1. 5 0
      lib/constants/IdentifierBase.h

+ 5 - 0
lib/constants/IdentifierBase.h

@@ -52,6 +52,11 @@ public:
 		num += change;
 	}
 
+	constexpr operator int32_t () const
+	{
+		return num;
+	}
+
 	friend std::ostream& operator<<(std::ostream& os, const IdentifierBase& dt)
 	{
 		return os << dt.num;