mirror of
https://github.com/pybind/pybind11.git
synced 2024-11-25 22:52:01 +00:00
Avoid copy in iteration by using const auto & (#4861)
This change is fixing a Coverity AUTO_CAUSES_COPY issues.
This commit is contained in:
parent
5891867ee4
commit
7e5edbc947
@ -1142,7 +1142,7 @@ protected:
|
|||||||
}
|
}
|
||||||
msg += "kwargs: ";
|
msg += "kwargs: ";
|
||||||
bool first = true;
|
bool first = true;
|
||||||
for (auto kwarg : kwargs) {
|
for (const auto &kwarg : kwargs) {
|
||||||
if (first) {
|
if (first) {
|
||||||
first = false;
|
first = false;
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user