Merge 78dfeedd0504b0a56dbbde04cc0567abe7b92e98 into e8e122e9ce46f4f1c0b04003d8b703fe1b89755a

This commit is contained in:
phwissmann 2024-03-05 13:09:56 +01:00 committed by GitHub
commit 291a8596ae
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 4 additions and 2 deletions

View File

@ -199,7 +199,7 @@ extern \"C\" {
file(TO_NATIVE_PATH "${LUA_VANILLA_SOURCE_LUA_HPP}" LUA_VANILLA_SOURCE_LUA_HPP)
endif()
set(LUA_VANILLA_INCLUDE_DIRS ${lua-vanilla_SOURCE_DIR}/include)
set(LUA_VANILLA_INCLUDE_DIRS ${lua-vanilla_SOURCE_DIR}/src)
endif()
# # Target names
@ -251,7 +251,9 @@ else()
endif()
target_compile_options(${liblua}
PRIVATE ${LUA_VANILLA_LUALIB_COMPILER_OPTIONS})
if(LUA_LOCAL_DIR)
add_dependencies(${liblua} LUA_VANILLA)
endif()
target_link_libraries(${liblua} PRIVATE ${CMAKE_DL_LIBS})
if (UNIX)
target_link_libraries(${liblua} PRIVATE m)

View File

@ -59,7 +59,7 @@ inline namespace sol2_regression_test_coroutines_array_proxy_lifetime {
value_type operator*() const {
size_t size = a.mpParent.children.size();
if (index >= 0 && index < size) {
if (index < size) {
return a.mpParent.children[index];
}
return std::weak_ptr<A>();