HomePhabricator

rpcwallet: Replace pwallet-> with wallet.

Description

rpcwallet: Replace pwallet-> with wallet.

Summary:

rpcwallet: Replace boost::optional<T>::emplace with simple assignment of T{}

Optional::emplace() was only added in boost 1.56, see
https://github.com/boostorg/optional/commit/2e583aaf30964afd66c1284aa71d0d8b42fa440d

To simply work around https://github.com/bitcoin/bitcoin/issues/18943,
replace it with assignment of T{}

https://github.com/bitcoin/bitcoin/pull/18946/commits/fa1f840596554ed264d11ee3b3643bf99eb57eb5
Backport note: Bitcoin ABC already enforces boost > 1.59, and uses std::optional anyway, so this first commit
is included only for future backporting convenience.


rpcwallet: Replace pwallet-> with wallet.

pwallet is never null everywhere where it is dereferenced, so simply
replace it with a reference, which can not be null by definition.

https://github.com/bitcoin/bitcoin/pull/18946/commits/fa1f840596554ed264d11ee3b3643bf99eb57eb5


This is a backport of Core PR18946

Test Plan: ninja all check-all

Reviewers: #bitcoin_abc, majcosta

Reviewed By: #bitcoin_abc, majcosta

Differential Revision: https://reviews.bitcoinabc.org/D9112

Details

Provenance
MarcoFalke <falke.marco@gmail.com>Authored on Jan 29 2021, 17:42
PiRKCommitted on Jan 29 2021, 17:42
abc-botPushed on Jan 29 2021, 17:49
Reviewer
Restricted Project
Differential Revision
D9112: rpcwallet: Replace pwallet-> with wallet.
Parents
rABC102f35022bec: build: ensure we aren't using GNU extensions
Branches
Unknown
Tags
Unknown