Skip to content

Commit

Permalink
Update merkle-proofs.md
Browse files Browse the repository at this point in the history
  • Loading branch information
ralexstokes authored Nov 7, 2021
1 parent e6b726b commit a9c62d8
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions ssz/merkle-proofs.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
- [Generalized Merkle tree index](#generalized-merkle-tree-index)
- [SSZ object to index](#ssz-object-to-index)
- [Helpers for generalized indices](#helpers-for-generalized-indices)
- [`concat_generalized_indices`](#concat_generalized_indices)
- [`get_generalized_index_length`](#get_generalized_index_length)
- [`get_generalized_index_bit`](#get_generalized_index_bit)
- [`generalized_index_sibling`](#generalized_index_sibling)
Expand Down Expand Up @@ -191,20 +190,6 @@ def get_generalized_index(typ: SSZType, path: Sequence[Union[int, SSZVariableNam

_Usage note: functions outside this section should manipulate generalized indices using only functions inside this section. This is to make it easier for developers to implement generalized indices with underlying representations other than bigints._

#### `concat_generalized_indices`

```python
def concat_generalized_indices(*indices: GeneralizedIndex) -> GeneralizedIndex:
"""
Given generalized indices i1 for A -> B, i2 for B -> C .... i_n for Y -> Z, returns
the generalized index for A -> Z.
"""
o = GeneralizedIndex(1)
for i in indices:
o = GeneralizedIndex(o * get_power_of_two_floor(i) + (i - get_power_of_two_floor(i)))
return o
```

#### `get_generalized_index_length`

```python
Expand Down

0 comments on commit a9c62d8

Please sign in to comment.