Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Copy HttpStatus::values to prevent allocation
Before this commit, HttpStatus::resolve used the values() method in its logic. This causes a new array to be allocated for each invocation, and results in memory overhead. This commit makes a copy of the HttpStatus values array, and uses that to resolve status codes. Closes gh-26842
- Loading branch information
Showing
1 changed file
with
10 additions
and
2 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
I guess this should be
use
instead ofused
?