Skip to content

序列化类型编码使用rtti,提供替代方案 #5

Description

@RFoe

co_await _M_put_tag(_S_condense(std::type_index{ typeid(T) }.hash_code()));

或许是这样

#if __cpp_rtti
std::type_index{ typeid(T) }.hash_code()
#else
static_hash<signature<T>()>()
#endif

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions