Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
AurevoirXavier committed Dec 6, 2023
1 parent af29b0c commit 17cd30f
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,16 @@
- type `[u8; N] -> String`, `N = { [1, 64], 128, 256, 512 }`
- type `&[u8] -> String`

#### `slice` prefixed functions
- Build fixed length `Array` from `Slice`
- type `&[T] -> [T; N]`
- Transform `Slice` to `G`
- type `&[T] -> G`
- e.g. `&[0_u8, ...] -> [u8; 20] -> H160`

#### `prefix` and `suffix` functions
- Prefixes/suffixes the given element to the given slice to make it a fixed-size array of length `N`.

#### `bytes` prefixed functions
- Convert bytes to hex
- type `AsRef<[u8]> -> String`
Expand All @@ -69,13 +79,6 @@
- type `AsRef<[u8]> -> T`
- e.g. `"0x..." -> [u8; 20] -> H160`

#### `slice` prefixed functions
- Build fixed length `Array` from `Slice`
- type `&[T] -> [T; N]`
- Transform `Slice` to `G`
- type `&[T] -> G`
- e.g. `&[0_u8, ...] -> [u8; 20] -> H160`

#### `vec` prefixed functions
- Build fixed length `Array` from `Vec`
- type `Vec<T> -> [T; N]`
Expand Down

0 comments on commit 17cd30f

Please sign in to comment.