LLNL / GridDyn

GridDyn is an open-source power transmission simulation software package

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

variant.hpp fails to compile with MSVC 19.15

nightlark opened this issue · comments

The variant.hpp file doesn't compile with MSVC 19.15; the issue for the bug on GitHub for the third party library is: mpark/variant#48
mpark/variant PR to disable constexpr in MSVC 2017: mpark/variant#49

And the compiler bug report on the Visual Studio developer community can be found at: https://developercommunity.visualstudio.com/content/problem/275141/c2131-expression-did-not-evaluate-to-a-constant-fo.html (upvoting will make it more likely to get fixed sooner)

Have you actually observed this issue, if so what warnings does it produce?

Yes, it produces the C2131 compiler error (expression not evaluating to a constant). It only affects versions of visual studio 2017 released in the past several months.

It looks like the variant has a fix that hasn't made it into the single_header version yet. So I have updated it. I will merge that once I get Corey's changes merged.

There's been a status update on the compiler bug report -- the 16.0 release will fix it (VS2019?).