MCPcopy Create free account
hub / github.com/AllentDan/LibtorchTutorials / reserve

Method reserve

lesson7-Detection/src/utils/tinystr.cpp:37–46  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

35
36
37void TiXmlString::reserve (size_type cap)
38{
39 if (cap > capacity())
40 {
41 TiXmlString tmp;
42 tmp.init(length(), cap);
43 memcpy(tmp.start(), data(), length());
44 swap(tmp);
45 }
46}
47
48
49TiXmlString& TiXmlString::assign(const char* str, size_type len)

Callers 6

from_json_array_implFunction · 0.80
constructMethod · 0.80
destroyFunction · 0.80
get_batchMethod · 0.80
tinyxml.cppFile · 0.80
operator +Function · 0.80

Calls 3

swapFunction · 0.85
initMethod · 0.80
startMethod · 0.80

Tested by

no test coverage detected