Skip to content

Commit c6da173

Browse files
authored
Update 2025-03-20-tiny-allocationless-json-parser-in-c.md
1 parent 1fe3dd6 commit c6da173

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

_posts/2025-03-20-tiny-allocationless-json-parser-in-c.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,12 +72,10 @@ The [JSON spec](https://www.json.org/json-en.html) specifies that the other valu
7272

7373
## Simpler version: restart on reallocation
7474

75-
If you don't mind the first JSON file taking a bit longer to be parsed, you can use the branch called [restart-on-reallocation](https://github.com/MyNameIsTrez/tiny-allocationless-json-parser-in-c/tree/restart-on-reallocation).
75+
If you don't mind the first JSON file taking a bit longer to be parsed, you can use the branch called [restart-on-reallocation](https://github.com/MyNameIsTrez/tiny-allocationless-json-parser-in-c/tree/restart-on-reallocation). It is 473 lines of code.
7676

7777
If one of the internal arrays is too small, it'll automatically restart the parsing, where the array's capacity is doubled [here](https://github.com/MyNameIsTrez/tiny-allocationless-json-parser-in-c/blob/1e5dd1ae77e3f247f28026cc10abedd876aa43f0/json.c#L375-L376). So the first parsed JSON file will take a few iterations to be parsed successfully, while the JSON files after that will usually just take a single iteration.
7878

79-
It is 473 lines of code.
80-
8179
## Even simpler version: structless
8280

8381
If you don't need to have several JSON files open at the same, so if you don't mind the code being stateful, you can use the branch called [structless](https://github.com/MyNameIsTrez/tiny-allocationless-json-parser-in-c/tree/structless):

0 commit comments

Comments
 (0)