Skip to content

non-type template argument is not a constant expression #2

@chlict

Description

@chlict

rev: f79f4ac
Compile error:

AllocTensor.hpp:49:81: error: non-type template argument is not a constant expression
        static_assert(hana::contains(decltype(hana::keys(map))(), hana::llong_c<lhs.getI()>));

Source code:

    if constexpr (is_temp<std::remove_reference_t<Lhs> >) {
        static_assert(hana::contains(decltype(hana::keys(map))(), hana::llong_c<lhs.getI()>));
    }

lhs.getI()是个temp_placeholder<1> &,lhs.getI()也是constexpr返回类型的函数,但是编译器不能正确识别。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions