-
Notifications
You must be signed in to change notification settings - Fork 97
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
oci: casext: mediatype: switch to generics for parser functions
We cannot use generics for the parser function map, but we can use it when instantiating "simple" JSON parser functions. There are a few other downsides to Go's generics, so this should just be a minor (possibly even theoretical) performance improvement over constructing the parsed types using reflection. Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>
- Loading branch information
Showing
1 changed file
with
55 additions
and
43 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