mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Fix clang-tidy warnings in torch/jit (#146963)
Fixes #ISSUE_NUMBER Pull Request resolved: https://github.com/pytorch/pytorch/pull/146963 Approved by: https://github.com/davidberard98
This commit is contained in:
@ -37,7 +37,7 @@ std::string stringSlice(
|
||||
slice_indices_adjust(string.size(), &start_val, &end_val, step);
|
||||
|
||||
int64_t i = start_val;
|
||||
std::string result = "";
|
||||
std::string result;
|
||||
for ([[maybe_unused]] const auto j : c10::irange(num_vals)) {
|
||||
result += string[i];
|
||||
i += step;
|
||||
|
Reference in New Issue
Block a user