buffer: improve Buffer#fill performance
1) This improves the performance for Buffer#fill by using shortcuts. 2) It also ports throwing errors to JS. That way they contain the proper error code. 3) Using negative `end` values will from now on result in an error instead of just doing nothing. 4) Passing in `null` as encoding is from now on accepted as 'utf8'. PR-URL: https://github.com/nodejs/node/pull/18790 Reviewed-By:James M Snell <jasnell@gmail.com> Reviewed-By:
Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By:
Matteo Collina <matteo.collina@gmail.com>
parent
d3af120f
Please register or sign in to comment