Skip to content

Commit 93d1b15

Browse files
committed
BIP341: add brackets to avoid ambiguity due to precendence rules around bipwise ops
1 parent ce5f89f commit 93d1b15

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bip-0341.mediawiki

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,7 @@ For Bitcoin mainnet and testnet3, these BIPs will be deployed by "version bits"
311311
walk = block;
312312
for (i = 0; i < 2016; i++) {
313313
walk = walk.parent;
314-
if (walk.nVersion & 0xE0000000 == 0x20000000 && (walk.nVersion >> bit) & 1 == 1) {
314+
if ((walk.nVersion & 0xE0000000) == 0x20000000 && ((walk.nVersion >> bit) & 1) == 1) {
315315
count++;
316316
}
317317
}

0 commit comments

Comments
 (0)