HomePhabricator

Merge #15622: Remove global symbols: Avoid using the global namespace if…

Description

Merge #15622: Remove global symbols: Avoid using the global namespace if possible

Summary:
fb434159d1 Remove global symbols: Avoid using the global namespace if possible (practicalswift)

Pull request description:

Remove global symbols: Avoid using the global namespace if possible.

Partially resolves #15612 ("Reduce the number of global symbols used").

Change in global symbols as reported by `nm bitcoind` before vs after:

```
$ diff -u <(nm src/bitcoind-before | c++filt | grep -E '^[0-9a-f]+ [A-Z] ' | cut -f3- -d' ' | sort -u) \
          <(nm src/bitcoind-after  | c++filt | grep -E '^[0-9a-f]+ [A-Z] ' | cut -f3- -d' ' | sort -u) \
          | grep -E '^[+-][^+-]'
-boundSockets
-cs_warnings
-eventHTTP
-fFeeEstimatesInitialized
-fLargeWorkForkFound
-fLargeWorkInvalidChainFound
-pathHandlers
-strMiscWarning[abi:cxx11]
-threadHTTP
```

ACKs for commit fb4341:

Tree-SHA512: d2f78f6188a992b0e0de8d107e2c494cfa0faa2de4fda634a1d3606d6515633bec86289cf2a2e78ffe467b17b795e2243cc459fb44e0dfe2fc69899506ff61c9

Backport of Core PR15622

Test Plan:
While the instructions in the summary do not appear to work, manually inspecting like:

diff -u <(nm src/bitcoind-before) <(nm src/bitcoind-after) | less

And searching for the above instances indicates they were removed as expected.

ninja check check-functional

Reviewers: #bitcoin_abc, deadalnix

Reviewed By: #bitcoin_abc, deadalnix

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

Details

Provenance
MarcoFalke <falke.marco@gmail.com>Authored on May 25 2019, 22:37
jasonbcoxCommitted on Jun 11 2020, 22:21
jasonbcoxPushed on Jun 11 2020, 22:21
Reviewer
Restricted Project
Differential Revision
D6516: Merge #15622: Remove global symbols: Avoid using the global namespace if possible
Parents
rABC54554de6b6cb: Merge #12980: Allow quicker shutdowns during LoadBlockIndex()
Branches
Unknown
Tags
Unknown