From e4210734663b5caed39f497c0d3705eeaa1bb455 Mon Sep 17 00:00:00 2001 From: Daniel Arndt Date: Sat, 25 Feb 2023 10:37:55 -0500 Subject: [PATCH] Fix errors in bundled packages --- .../boost-1.70.0/include/boost/graph/depth_first_search.hpp | 2 +- bundled/tbb-2018_U2/src/tbb/cache_aligned_allocator.cpp | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/bundled/boost-1.70.0/include/boost/graph/depth_first_search.hpp b/bundled/boost-1.70.0/include/boost/graph/depth_first_search.hpp index cf60e1ac84..e9b41bcf71 100644 --- a/bundled/boost-1.70.0/include/boost/graph/depth_first_search.hpp +++ b/bundled/boost-1.70.0/include/boost/graph/depth_first_search.hpp @@ -156,7 +156,7 @@ namespace boost { ColorValue v_color = get(color, v); if (v_color == Color::white()) { vis.tree_edge(*ei, g); - src_e = *ei; + src_e = decltype(src_e)(*ei); stack.push_back(std::make_pair(u, std::make_pair(src_e, std::make_pair(++ei, ei_end)))); u = v; put(color, u, Color::gray()); diff --git a/bundled/tbb-2018_U2/src/tbb/cache_aligned_allocator.cpp b/bundled/tbb-2018_U2/src/tbb/cache_aligned_allocator.cpp index e1e8713206..21cb209ee5 100644 --- a/bundled/tbb-2018_U2/src/tbb/cache_aligned_allocator.cpp +++ b/bundled/tbb-2018_U2/src/tbb/cache_aligned_allocator.cpp @@ -248,9 +248,10 @@ bool __TBB_EXPORTED_FUNC is_malloc_used_v3() { } __TBB_ASSERT( MallocHandler!=&DummyMalloc && FreeHandler!=&DummyFree, NULL ); // Cast to void avoids type mismatch errors on some compilers (e.g. __IBMCPP__) - __TBB_ASSERT( !(((void*)MallocHandler==(void*)&malloc) ^ ((void*)FreeHandler==(void*)&free)), + __TBB_ASSERT( !(((void*)MallocHandler==(void*)static_cast(malloc)) ^ + ((void*)FreeHandler==(void*)static_cast(free))), "Both shim pointers must refer to routines from the same package (either TBB or CRT)" ); - return (void*)MallocHandler == (void*)&malloc; + return (void*)MallocHandler == (void*)static_cast(malloc); } } // namespace internal -- 2.39.5