Merge pull request #502 from open-source-parsers/null-object

Allow dtor for nullSingleton
This commit is contained in:
Christopher Dunn 2016-07-20 22:28:44 -07:00 committed by GitHub
commit b14c8c1423

View File

@ -39,8 +39,8 @@ namespace Json {
// static // static
Value const& Value::nullSingleton() Value const& Value::nullSingleton()
{ {
static Value const* nullStatic = new Value; static Value const nullStatic;
return *nullStatic; return nullStatic;
} }
// for backwards compatibility, we'll leave these global references around, but DO NOT // for backwards compatibility, we'll leave these global references around, but DO NOT