MCPcopy Create free account
hub / github.com/awslabs/aws-lambda-cpp / ~ThreadLocal

Function ~ThreadLocal

tests/gtest/gtest.h:2025–2032  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2023 default_factory_(new InstanceValueHolderFactory(value)) {}
2024
2025 ~ThreadLocal() {
2026 // Destroys the managed object for the current thread, if any.
2027 DeleteThreadLocalValue(pthread_getspecific(key_));
2028
2029 // Releases resources associated with the key. This will *not*
2030 // delete managed objects for other threads.
2031 GTEST_CHECK_POSIX_SUCCESS_(pthread_key_delete(key_));
2032 }
2033
2034 T* pointer() { return GetOrCreateValue(); }
2035 const T* pointer() const { return GetOrCreateValue(); }

Callers

nothing calls this directly

Calls 1

DeleteThreadLocalValueFunction · 0.85

Tested by

no test coverage detected