Commit c9f0ed55 authored by Andrii Grynenko's avatar Andrii Grynenko Committed by Dave Watson

remove get_weak from singleton

Summary:

Test Plan: fbmake runtests, OBC no longer segfaults

Reviewed By: mshneer@fb.com

Subscribers: fbcode-common-diffs@, trunkagent, mcduff, marccelani, hitesh, mshneer, njormrod, lins

FB internal diff: D1573880
parent eb9847c8
...@@ -409,10 +409,6 @@ class Singleton { ...@@ -409,10 +409,6 @@ class Singleton {
return std::weak_ptr<T>(get_shared({typeid(T), name}, vault)); return std::weak_ptr<T>(get_shared({typeid(T), name}, vault));
} }
std::weak_ptr<T> get_weak(const char* name) {
return std::weak_ptr<T>(get_shared({typeid(T), name}, vault_));
}
// Allow the Singleton<t> instance to also retrieve the underlying // Allow the Singleton<t> instance to also retrieve the underlying
// singleton, if desired. // singleton, if desired.
T* ptr() { return get_ptr(type_descriptor_, vault_); } T* ptr() { return get_ptr(type_descriptor_, vault_); }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment