This workaround is needed to fix “parameter pack may not be accessed at an out of bounds index” compile errors in https://github.com/bitcoin/bitcoin/pull/29409 due in sanitizer jobs due to https://github.com/bitcoin/bitcoin/pull/34660 which updates sanitizers to use LLVM 22 instead of LLVM 21:
https://github.com/bitcoin/bitcoin/actions/runs/22501264518/job/65188721708?pr=29409 https://github.com/bitcoin/bitcoin/actions/runs/22501264518/job/65188721733?pr=29409
0/cxx_build/include/c++/v1/__fwd/tuple.h:40:52: error: a parameter pack may not be accessed at an out of bounds index
1 40 | using type _LIBCPP_NODEBUG = __type_pack_element<_Ip, _Tp...>;
2 | ^
3/cxx_build/include/c++/v1/__utility/try_key_extraction.h:82:67: note: in instantiation of template class 'std::tuple_element<0, std::tuple<>>' requested here
4 82 | is_same<__remove_const_ref_t<typename tuple_element<0, _Tuple1>::type>, _KeyT>::value,
5 | ^
The upstream LLVM bug is https://github.com/llvm/llvm-project/issues/167709 and fix is https://github.com/llvm/llvm-project/pull/183614