-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(bincode): extract hashmap and arraylist code to field configs (
#265) This takes all the custom logic from bincode.read and bincode.write that was written for hashmaps and arraylists, and it moves it to functions that return it as a FieldConfig in bincode/hashmap.zig and bincode/arraylist.zig. This `hashmap` field in FieldConfig is no longer needed, since this can be specified directly instead. The `getConfig` function automatically applies the hashmap and arraylist FieldConfig for compatible types that don't have another config already. Long term there may be a better or more flexible way to include standard configs (maybe in Params?) but this was the easiest place to put it for now.
- Loading branch information
Showing
6 changed files
with
202 additions
and
152 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.