Add non-strict mode to folly::Singleton
authorChip Turner <chip@fb.com>
Fri, 12 Sep 2014 00:36:50 +0000 (17:36 -0700)
committerDave Watson <davejwatson@fb.com>
Mon, 15 Sep 2014 21:30:20 +0000 (14:30 -0700)
commit736c0e46c4b541597d36f0f9c5ea99cb6ef828d1
treec4e17d1fd49183937c339cdf2118fbe299c96ddf
parent6b82bb37845de2c5f4885fd2527e9a4a77bb0129
Add non-strict mode to folly::Singleton

Summary:
It is difficult to guarantee every binary can call
registrationComplete; for now, support a mode where we don't enforce the
strict registration lifecycle.  In the fullness of time, we can make
strictness the default.

Test Plan: runtests

Reviewed By: lins@fb.com

Subscribers: lins, anca, njormrod

FB internal diff: D1551688
folly/experimental/Singleton.h
folly/experimental/test/SingletonTest.cpp