go-extend collects some commonly used operation functions to help complete development work faster and reduce duplicate code.
It collects various miscellaneous functions and categorizes them to make it easier for users to find them. It can greatly improve development efficiency and program running performance. It provides effective methods with the greatest premise of ensuring performance. Make some modifications to some functions or libraries in the standard library to greatly improve their performance, but it is not used to replace the standard library functions. These functions are often effective in some scenarios, but some functions can be used to replace the standard library functions. , they maintain consistent functionality and are quite secure.
Some package or function usage examples and analysis can be found on my blog (https://blog.thinkeridea.com).
$ go get github.com/thinkeridea/go-extend/...
ex
prefix consistent with the standard library package name to avoid conflicts with standard library packages.doc.go
in the package directory serves as the package description document Some functions in the package will undergo performance testing, including performance comparison of each revision. They are generally located in benchmark
directory under the respective package. The performance test results can be quickly browsed in benchmark.md.
Used to replace the functions of the standard library. They have the same functions as the standard library functions and have better performance:
Use this function to improve the standard library. They have basically the same functionality as the standard library, but they all have better performance:
[]byte
type, effectively avoiding type conversion[]byte
type, effectively avoiding type conversion[]byte
type, effectively avoiding type conversion[]byte
type and performs in-place replacement. It cannot receive a literal string, otherwise a serious error will occur. go-extend is licensed under the MIT License, see LICENSE for the full license text