Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error "expression did not evaluate to a constant" with latest MSVC 19.8.5 #60

Open
emmenlau opened this issue Feb 11, 2021 · 0 comments

Comments

@emmenlau
Copy link
Contributor

emmenlau commented Feb 11, 2021

With the latest master branch and latest MSVC 19.8.5, I get an error in the build:

C:\gitlabci\local\builds\U8oUWsz8\0\BioDataAnalysis\NamedType\test\tests.cpp(528,29): error C2131: expression did not evaluate to a constant
    static_assert((10_meter == 10_meter), "Comparable is not constexpr");
                            ^
C:\gitlabci\local\builds\U8oUWsz8\0\BioDataAnalysis\NamedType\include\NamedType\named_type_impl.hpp(83,16): note: failure was caused by attempting to access a member on an object of dynamic type 'fluent::Comparable<fluent::NamedType<unsigned __int64,MeterParameter,fluent::Addable,fluent::Comparable>>' in which the member is not defined
        return value_;
               ^
C:\gitlabci\local\builds\U8oUWsz8\0\BioDataAnalysis\NamedType\include\NamedType\named_type_impl.hpp(83,16): note: see usage of 'fluent::NamedType<unsigned __int64,MeterParameter,fluent::Addable,fluent::Comparable>::value_'
        return value_;

I think this test is originating from commit 1841331 "Adding constexpr for skill Comparable".

I have set a preprocessor define to enable explicit -std:c++17, but that should be ok, or not?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant