MCPcopy Create free account
hub / github.com/bab2min/tomotopy / decref

Method decref

src/Utils/SharedString.cpp:13–23  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

11 }
12
13 void SharedString::decref()
14 {
15 if (ptr)
16 {
17 if (--*(size_t*)ptr == 0)
18 {
19 delete[] ptr;
20 ptr = nullptr;
21 }
22 }
23 }
24
25 void SharedString::init(const char* _begin, const char* _end)
26 {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected