> As described in `util/ref.h`: "This implements a small subset of the functionality in C++17's `std::any` class, and can be dropped when the project updates to C++17". For accessing the contained object of a `std::any` instance, a helper template function `AnyPtr` is introduced (thanks to ryanofsky).
This is a backport of [[https://github.com/bitcoin/bitcoin/pull/21366 | core#21366]] [2/3]
https://github.com/bitcoin/bitcoin/pull/21366/commits/8dbb87a3932f81e23ba7afd865b9aeeb535f0c20
Depends on D11550
Note: due to D1736, the context is sometimes wrapped in `HTTPRPCRequestProcessor` instead of being passed directly as a parameter