Skip to content

VS2017 compiler suggests using constexpr if #1204

@DragonOsman

Description

@DragonOsman

I'm making a bug report, but it's not really a bug. It's something between a bug and a feature request. Basically, the MSVC compiler (latest version in VS2017) is suggesting to use constexpr if in the file single_include\nlohmann\json,hpp on line 1966. The warning is:

warning C4127: conditional expression is constant
note: consider using 'if constexpr' statement instead

Also, on single_include\nlohmann\json.hpp(1962) (`962 is the line number):

note: while compiling class template member function 'std::char_traits<char>::int_type nlohmann::detail::wide_string_input_adapter<std::u32string>::get_character(void) noexcept'

Metadata

Metadata

Assignees

Labels

solution: proposed fixa fix for the issue has been proposed and waits for confirmation

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions