mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-03-15 01:55:22 +01:00
Use -Wswitch for TxoutType where possible
This commit is contained in:
@@ -106,8 +106,7 @@ static bool SignStep(const SigningProvider& provider, const BaseSignatureCreator
|
||||
std::vector<valtype> vSolutions;
|
||||
whichTypeRet = Solver(scriptPubKey, vSolutions);
|
||||
|
||||
switch (whichTypeRet)
|
||||
{
|
||||
switch (whichTypeRet) {
|
||||
case TxoutType::NONSTANDARD:
|
||||
case TxoutType::NULL_DATA:
|
||||
case TxoutType::WITNESS_UNKNOWN:
|
||||
@@ -173,10 +172,8 @@ static bool SignStep(const SigningProvider& provider, const BaseSignatureCreator
|
||||
// Could not find witnessScript, add to missing
|
||||
sigdata.missing_witness_script = uint256(vSolutions[0]);
|
||||
return false;
|
||||
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
} // no default case, so the compiler can warn about missing cases
|
||||
assert(false);
|
||||
}
|
||||
|
||||
static CScript PushAll(const std::vector<valtype>& values)
|
||||
|
||||
Reference in New Issue
Block a user