aboutsummaryrefslogtreecommitdiff
path: root/src/chainparams.h
diff options
context:
space:
mode:
authorTheCharlatan <seb.kung@gmail.com>2023-05-09 22:03:50 +0200
committerTheCharlatan <seb.kung@gmail.com>2023-05-10 10:39:58 +0200
commite23088707be2c3bf247f4b777290c8e401db48cb (patch)
tree2bbdefb0d41490d825b9464b37b00bbddc93b1e9 /src/chainparams.h
parentfc06881f13495154c888a64a38c7d538baf00435 (diff)
downloadbitcoin-e23088707be2c3bf247f4b777290c8e401db48cb.tar.xz
refactor: Use ChainType enum exhaustively
This is a follow up of https://github.com/bitcoin/bitcoin/pull/27491, more concretely https://github.com/bitcoin/bitcoin/pull/27491#discussion_r1188847896, for not using default cases (as per the style guide), and https://github.com/bitcoin/bitcoin/pull/27491#discussion_r1188852707 and https://github.com/bitcoin/bitcoin/pull/27491#discussion_r1188851857 for avoiding dead code. Also change chain name to chain type in docstrings
Diffstat (limited to 'src/chainparams.h')
-rw-r--r--src/chainparams.h5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/chainparams.h b/src/chainparams.h
index 6a65f40f80..1e8366dcf5 100644
--- a/src/chainparams.h
+++ b/src/chainparams.h
@@ -25,8 +25,6 @@ class ArgsManager;
/**
* Creates and returns a std::unique_ptr<CChainParams> of the chosen chain.
- * @returns a CChainParams* of the chosen chain.
- * @throws a std::runtime_error if the chain is not supported.
*/
std::unique_ptr<const CChainParams> CreateChainParams(const ArgsManager& args, const ChainType chain);
@@ -37,8 +35,7 @@ std::unique_ptr<const CChainParams> CreateChainParams(const ArgsManager& args, c
const CChainParams &Params();
/**
- * Sets the params returned by Params() to those for the given chain name.
- * @throws std::runtime_error when the chain is not supported.
+ * Sets the params returned by Params() to those for the given chain type.
*/
void SelectParams(const ChainType chain);