Commit c23b7977 authored by Orvid King's avatar Orvid King Committed by facebook-github-bot-4

Add typename qualifiers to Singleton.h

Summary: MSVC complains if these are not there.
Closes #248

Reviewed By: @yfeldblum

Differential Revision: D2282845

Pulled By: @sgolemon
parent a51326dc
......@@ -453,12 +453,12 @@ class Singleton {
T* operator->() { return get(); }
explicit Singleton(std::nullptr_t _ = nullptr,
Singleton::TeardownFunc t = nullptr) :
typename Singleton::TeardownFunc t = nullptr) :
Singleton ([]() { return new T; }, std::move(t)) {
}
explicit Singleton(Singleton::CreateFunc c,
Singleton::TeardownFunc t = nullptr) {
explicit Singleton(typename Singleton::CreateFunc c,
typename Singleton::TeardownFunc t = nullptr) {
if (c == nullptr) {
throw std::logic_error(
"nullptr_t should be passed if you want T to be default constructed");
......
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