MCPcopy Create free account
hub / github.com/pybind/pybind11 / convert_iterable

Function convert_iterable

include/pybind11/stl.h:170–179  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

168 void reserve_maybe(const anyset &, void *) {}
169
170 bool convert_iterable(const iterable &itbl, bool convert) {
171 for (const auto &it : itbl) {
172 key_conv conv;
173 if (!conv.load(it, convert)) {
174 return false;
175 }
176 value.insert(cast_op<Key &&>(std::move(conv)));
177 }
178 return true;
179 }
180
181 bool convert_anyset(const anyset &s, bool convert) {
182 value.clear();

Callers 2

convert_anysetFunction · 0.85
loadFunction · 0.85

Calls 3

moveFunction · 0.85
insertMethod · 0.80
loadMethod · 0.45

Tested by

no test coverage detected