HomePhabricator

scripted-diff: TxoutType C++11 scoped enum class

Description

scripted-diff: TxoutType C++11 scoped enum class

Summary:

Non-scoped enums can accidentally and silently decay into an integral
type. Also, the symbol names of the keys are exported to the surrounding
(usually global) namespace.

Fix both issues by switching to an enum class TxoutType in a (mostly)
scripted-diff.

Backport of core PR19114.

Depends on D9124.

Test Plan:

ninja all check-all
ninja bitcoin-fuzzers

Reviewers: #bitcoin_abc, majcosta

Reviewed By: #bitcoin_abc, majcosta

Subscribers: PiRK

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

Details

Provenance
MarcoFalke <falke.marco@gmail.com>Authored on May 30 2020, 14:11
FabienCommitted on Feb 2 2021, 07:37
FabienPushed on Feb 2 2021, 07:38
Reviewer
Restricted Project
Differential Revision
D9126: scripted-diff: TxoutType C++11 scoped enum class
Parents
rABCd56bef9201d0: refactor: Replace const char* to std::string
Branches
Unknown
Tags
Unknown