Skip to content

Commit 7923b9d

Browse files
committed
chore: Reduce potential for error ID fragmentation
1 parent 8d22566 commit 7923b9d

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

tasm-lib/src/assertion_error_ids.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,7 @@ often.
1818
| Error IDs | Snippet |
1919
|----------:|:--------------------------------------------------------------------------------------------|
2020
| 0..10 | [`MerkleVerify`](hashing/merkle_verify.rs) |
21-
| 10..11 | [`MmrVerifyFromSecretInLeafIndexOnStack`](mmr/verify_from_secret_in_leaf_index_on_stack.rs) |
22-
| 11..20 | [`BagPeaks`](mmr/bag_peaks.rs) |
21+
| 10..20 | [`MmrVerifyFromSecretInLeafIndexOnStack`](mmr/verify_from_secret_in_leaf_index_on_stack.rs) |
2322
| 20..30 | [`MmrVerifyFromSecretInSecretLeafIndex`](mmr/verify_from_secret_in_secret_leaf_index.rs) |
2423
| 30..40 | [`VerifyFriAuthenticationPaths`](verifier/fri/verify_fri_authentication_paths.rs) |
2524
| 40..50 | [`VerifyTableRows`](verifier/master_table/verify_table_rows.rs) |
@@ -65,3 +64,4 @@ often.
6564
| 530..540 | [`u128::ShiftLeft`](arithmetic/u128/shift_left.rs) |
6665
| 540..550 | [`u128::ShiftRight`](arithmetic/u128/shift_right.rs) |
6766
| 550..560 | [`list::Range`](list/range.rs) |
67+
| 560..570 | [`BagPeaks`](mmr/bag_peaks.rs) |

tasm-lib/src/mmr/bag_peaks.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ use crate::traits::basic_snippet::SignOffFingerprint;
3939
pub struct BagPeaks;
4040

4141
impl BagPeaks {
42-
const INCONSISTENT_PEAKS_NUM: usize = 11;
42+
const INCONSISTENT_NUM_PEAKS_ERROR_ID: usize = 560;
4343
}
4444

4545
impl BasicSnippet for BagPeaks {
@@ -85,7 +85,7 @@ impl BasicSnippet for BagPeaks {
8585
dup 1 eq
8686
// _ *peaks [leaf_count] pop_count (num_peaks==pop_count)
8787

88-
assert error_id {Self::INCONSISTENT_PEAKS_NUM}
88+
assert error_id {Self::INCONSISTENT_NUM_PEAKS_ERROR_ID}
8989
hint num_peaks: u32 = stack[0]
9090
// _ *peaks [leaf_count] num_peaks
9191

0 commit comments

Comments
 (0)