Commit de00546
authored
Automated parsabilety of hex numbers ("0x...") (#35)
* Automated parsabilety of hex numbers starting with "0x"
When the NM client parses something like a Dictionary from JSON where input keys look like this:
"0x0000000000000000000000000000000000000000000000000000000000000000"
we currently fail. To fix this, we need to re-implement the dictionary parser as they do here (https://stackoverflow.com/a/7010231/1973207 ) with explicit `(UInt256)BigInteger.Parse(skey.Substring(2), NumberStyles.HexNumber);` in it. This would help automate this and allow the elimination of specialised dictionary parsers like that.1 parent 4cf50ea commit de00546
File tree
2 files changed
+15
-4
lines changed- src
- Nethermind.Int256.Test
- Nethermind.Int256
2 files changed
+15
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
| 2 | + | |
2 | 3 | | |
3 | 4 | | |
4 | 5 | | |
| |||
469 | 470 | | |
470 | 471 | | |
471 | 472 | | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
472 | 481 | | |
473 | 482 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
1882 | 1882 | | |
1883 | 1883 | | |
1884 | 1884 | | |
1885 | | - | |
| 1885 | + | |
1886 | 1886 | | |
1887 | | - | |
| 1887 | + | |
| 1888 | + | |
| 1889 | + | |
1888 | 1890 | | |
1889 | 1891 | | |
1890 | 1892 | | |
| |||
0 commit comments