mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-25 10:58:52 +00:00
Fix compilation with MSVC 19.
This commit is contained in:
parent
f500a287d4
commit
adf62c3184
@ -1069,6 +1069,13 @@ if(MSVC)
|
||||
set(CMAKE_CXX_FLAGS_MINSIZEREL "${CMAKE_CXX_FLAGS_MINSIZEREL} /Zc:wchar_t-")
|
||||
endif()
|
||||
|
||||
if (MSVC_VERSION GREATER_EQUAL 1914)
|
||||
# Ensure the __cplusplus macro is set to a sensible value.
|
||||
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /Zc:__cplusplus")
|
||||
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /Zc:__cplusplus")
|
||||
set(CMAKE_CXX_FLAGS_MINSIZEREL "${CMAKE_CXX_FLAGS_MINSIZEREL} /Zc:__cplusplus")
|
||||
endif()
|
||||
|
||||
message(STATUS "----- Warning level : ${CMAKE_CXX_WARNING_LEVEL} ${WARNING_LEVEL_MESSAGE}")
|
||||
message(STATUS "----- Warnings as errors : ${MSVC_W_ERROR}")
|
||||
message(STATUS "----- Warnings disabled : ${MSVC_W_DISABLE}")
|
||||
|
@ -296,7 +296,7 @@ public:
|
||||
|
||||
const_iterator iterator_at(size_t i) const
|
||||
{
|
||||
return (i == size()) ? end() : iterCont_[i];
|
||||
return (i == size()) ? end() : const_iterator(iterCont_[i]);
|
||||
}
|
||||
|
||||
iterator iterator_at(size_t i)
|
||||
|
Loading…
Reference in New Issue
Block a user