-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
✨ (v3) feature: Implement new generic functions: Params, Get and Conv…
…ert (#2850) * feature: implement generic params function * update: add ctx generic params benchmark function * fix: fix linter errors on boolean types * fix: fix linter errors on float variable types * tests: add Test_Params_TypeAssertFail Co-authored-by: Jason McNeil <[email protected]> * Update ctx_test.go * typo: change genericType typo to GenericType in documents * remove ParamsInt method and rewrite Params method * add genericParseType tests and benchmarks and simplify genericQuery and genericParams tests and benchmarks * added GetReqHeader generic function * added tests for params generic function * add tests for GetReqHeader generic function * added GetReqHeader generic function * Revert "added GetReqHeader generic function" This reverts commit a63cebb. * fix tests and benchamarks of generic tests * added default value to array test genericParse * fix Params generic function on default value and fixes some tests and typos * remove Test_Params_TypeAssertFail function(it didn't panic anyway) * fix bad usage on parallel tests * add convert function * fix generic tests * fix fail tests on use parallel multiple time * fix typo on params comment section * remove pointer refer on Convert * update generic benchmarks * reslove conflicts1 * add specific tests to integer and unsigned integer generic parser * fix typo on Convert document * change uint tests of Test_genericParseTypeInts * move generic types to utils.go file and change bitsize of int value type to 0 * update genericParseInt unit tests * update generic uint tests and pass value type in check functions * reverse dependency of Params and genericParams * update convert docs --------- Co-authored-by: Jason McNeil <[email protected]> Co-authored-by: Juan Calderon-Perez <[email protected]> Co-authored-by: RW <[email protected]>
- Loading branch information
1 parent
82070cb
commit 43dc60f
Showing
5 changed files
with
1,376 additions
and
627 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
Oops, something went wrong.
43dc60f
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Possible performance regression was detected for benchmark.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold
2
.Benchmark_Etag
200
ns/op 0 B/op 0 allocs/op98.08
ns/op 0 B/op 0 allocs/op2.04
Benchmark_Middleware_Favicon
208.9
ns/op 12 B/op 4 allocs/op90.01
ns/op 3 B/op 1 allocs/op2.32
This comment was automatically generated by workflow using github-action-benchmark.